@content-blocks/js 0.7.6 → 0.8.0
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/LICENSE +1 -1
- package/README.md +111 -3
- package/THIRD-PARTY-NOTICES.md +21 -0
- package/dist/cjs/{app-globals-3a1e7e63.js → app-globals-V2Kpy_OQ.js} +0 -2
- package/dist/cjs/content-accordion.cjs.entry.js +87 -0
- package/dist/cjs/content-blocks.cjs.js +35 -11
- package/dist/cjs/content-button.cjs.entry.js +113 -0
- package/dist/cjs/content-carousel.cjs.entry.js +153 -47
- package/dist/cjs/content-grid-formatter.cjs.entry.js +102 -0
- package/dist/cjs/content-hero-block.cjs.entry.js +45 -0
- package/dist/cjs/content-image.cjs.entry.js +153 -0
- package/dist/cjs/content-line.cjs.entry.js +61 -0
- package/dist/cjs/content-navigation-block.cjs.entry.js +51 -34
- package/dist/cjs/content-overlay.cjs.entry.js +641 -0
- package/dist/cjs/content-spacer.cjs.entry.js +75 -0
- package/dist/cjs/content-split-block.cjs.entry.js +22 -19
- package/dist/cjs/content-tabs.cjs.entry.js +38 -21
- package/dist/cjs/content-text-block.cjs.entry.js +63 -0
- package/dist/cjs/content-tout-block.cjs.entry.js +34 -0
- package/dist/cjs/{content-accordion_11.cjs.entry.js → content-video.cjs.entry.js} +14560 -12927
- package/dist/cjs/{focus-trap.esm-7bc384a0.js → focus-trap.esm-ZwN-anf1.js} +484 -190
- package/dist/cjs/{index-2e0ce692.js → index-B1U6Gweq.js} +348 -246
- package/dist/cjs/index-ClnpH9XB.js +2170 -0
- package/dist/cjs/index-CyalvZJn.js +1719 -0
- package/dist/cjs/index-DUvWvBDN.js +290 -0
- package/dist/cjs/index-voGY4Tkl.js +4705 -0
- package/dist/cjs/index.cjs.js +2 -5
- package/dist/cjs/loader.cjs.js +3 -8
- package/dist/cjs/responsive-component-C5eJS82z.js +171 -0
- package/dist/cjs/responsive-component-DMdnQIPV.js +171 -0
- package/dist/cjs/swiper-KLYbvU1K.js +3931 -0
- package/dist/cjs/{swiper-8221f4e8.js → swiper-_Z8Y4IJI.js} +269 -236
- package/dist/cjs/utils-BCHaRGm_.js +462 -0
- package/dist/cjs/{utils-df044337.js → utils-C3gXIS2t.js} +51 -49
- package/dist/cjs/utils-DUvWvBDN.js +290 -0
- package/dist/collection/blocks/content-hero-block/content-hero-block.css +1 -1
- package/dist/collection/blocks/content-hero-block/content-hero-block.js +33 -48
- package/dist/collection/blocks/content-split-block/content-split-block.css +16 -5
- package/dist/collection/blocks/content-split-block/content-split-block.js +29 -48
- package/dist/collection/blocks/content-text-block/content-text-block.js +65 -59
- package/dist/collection/blocks/content-tout-block/content-tout-block.css +3 -0
- package/dist/collection/blocks/content-tout-block/content-tout-block.js +22 -47
- package/dist/collection/collection-manifest.json +8 -5
- package/dist/collection/components/content-accordion/content-accordion.css +20 -1
- package/dist/collection/components/content-accordion/content-accordion.js +67 -33
- package/dist/collection/components/content-accordion/libraries/w3_disclosure_button.js +0 -1
- package/dist/collection/components/content-carousel/content-carousel.css +60 -4
- package/dist/collection/components/content-carousel/content-carousel.js +294 -44
- package/dist/collection/components/content-navigation-block/content-navigation-block.css +15 -1
- package/dist/collection/components/content-navigation-block/content-navigation-block.js +86 -42
- package/dist/collection/components/content-overlay/content-overlay.css +36 -5
- package/dist/collection/components/content-overlay/content-overlay.js +181 -120
- package/dist/collection/components/content-overlay/libraries/aria-dialog.js +0 -1
- package/dist/collection/components/content-overlay/libraries/aria-utilities.js +0 -1
- package/dist/collection/components/content-tabs/content-tabs.js +7 -49
- package/dist/collection/components/content-tabs/libraries/w3_tabs.js +0 -1
- package/dist/collection/elements/content-button/content-button.css +8 -7
- package/dist/collection/elements/content-button/content-button.js +103 -84
- package/dist/collection/elements/content-image/content-image.css +3 -1
- package/dist/collection/elements/content-image/content-image.js +176 -95
- package/dist/collection/elements/content-line/content-line.js +63 -54
- package/dist/collection/elements/content-video/content-video.css +1 -1
- package/dist/collection/elements/content-video/content-video.js +165 -92
- package/dist/collection/formatters/content-grid-formatter/content-grid-formatter.css +8 -2
- package/dist/collection/formatters/content-grid-formatter/content-grid-formatter.js +167 -89
- package/dist/collection/formatters/content-spacer/content-spacer.js +86 -209
- package/dist/collection/global/content-blocks-reset.css +77 -0
- package/dist/collection/index.js +1 -1
- package/dist/collection/sass/_mixins.scss +21 -5
- package/dist/collection/sass/_variables.scss +15 -15
- package/dist/collection/setupFiles.js +0 -1
- package/dist/collection/site/site.js +67 -0
- package/dist/collection/utils/breakpoints.js +162 -0
- package/dist/collection/utils/responsive-component.js +249 -0
- package/dist/collection/utils/utils.js +32 -42
- package/dist/components/content-accordion.js +65 -44
- package/dist/components/content-button.js +89 -43
- package/dist/components/content-carousel.js +172 -55
- package/dist/components/content-grid-formatter.js +127 -3
- package/dist/components/content-hero-block.js +33 -26
- package/dist/components/content-image.js +127 -71
- package/dist/components/content-line.js +56 -35
- package/dist/components/content-navigation-block.js +62 -39
- package/dist/components/content-overlay.js +128 -67
- package/dist/components/content-spacer.js +70 -54
- package/dist/components/content-split-block.js +33 -32
- package/dist/components/content-tabs.js +46 -25
- package/dist/components/content-text-block.js +55 -35
- package/dist/components/content-tout-block.js +29 -27
- package/dist/components/content-video.js +14624 -11972
- package/dist/{esm/focus-trap.esm-8fb54175.js → components/focus-trap.esm.js} +484 -190
- package/dist/components/index.d.ts +2 -0
- package/dist/components/index.js +3 -3
- package/dist/components/{p-5a91aa1b.js → index2.js} +348 -246
- package/dist/components/p-BWRCeMvO.js +1 -0
- package/dist/components/p-CYF5GU_q.js +1 -0
- package/dist/components/p-DXUoPIwl.js +10 -0
- package/dist/components/p-D_Ll4QNj.js +1 -0
- package/dist/components/p-DhIoW7H3.js +1 -0
- package/dist/components/responsive-component.js +168 -0
- package/dist/components/{p-e5dc4ea4.js → swiper.js} +268 -235
- package/dist/components/utils.js +4969 -0
- package/dist/{esm/utils-1c9f0ec1.js → components/utils2.js} +51 -50
- package/dist/content-blocks/content-accordion.entry.js +85 -0
- package/dist/content-blocks/content-blocks.esm.js +47 -2
- package/dist/content-blocks/content-button.entry.js +111 -0
- package/dist/content-blocks/content-carousel.entry.js +188 -0
- package/dist/content-blocks/content-grid-formatter.entry.js +100 -0
- package/dist/content-blocks/content-hero-block.entry.js +43 -0
- package/dist/content-blocks/content-image.entry.js +151 -0
- package/dist/content-blocks/content-line.entry.js +59 -0
- package/dist/content-blocks/content-navigation-block.entry.js +105 -0
- package/dist/content-blocks/content-overlay.entry.js +639 -0
- package/dist/content-blocks/content-spacer.entry.js +73 -0
- package/dist/content-blocks/content-split-block.entry.js +34 -0
- package/dist/content-blocks/content-tabs.entry.js +245 -0
- package/dist/content-blocks/content-text-block.entry.js +61 -0
- package/dist/content-blocks/content-tout-block.entry.js +32 -0
- package/dist/{esm/content-accordion_11.entry.js → content-blocks/content-video.entry.js} +14535 -12890
- package/dist/{components/p-a2fedf8a.js → content-blocks/focus-trap.esm-DXUoPIwl.js} +484 -190
- package/dist/content-blocks/global/content-blocks-reset.css +77 -0
- package/dist/content-blocks/index-BFDJMblF.js +4690 -0
- package/dist/{esm/index-f45a9c45.js → content-blocks/index-P1YnSd-O.js} +348 -246
- package/dist/content-blocks/index.esm.js +1 -2
- package/dist/content-blocks/p-008457f0.entry.js +1 -0
- package/dist/content-blocks/p-052692f1.entry.js +1 -0
- package/dist/content-blocks/p-0f71bd32.entry.js +1 -0
- package/dist/content-blocks/p-1f154617.entry.js +1 -0
- package/dist/content-blocks/p-2554ebd8.entry.js +1 -0
- package/dist/content-blocks/p-4afd6511.entry.js +1 -0
- package/dist/content-blocks/p-78d5de9f.entry.js +1 -0
- package/dist/content-blocks/p-7bcf7e7e.entry.js +1 -0
- package/dist/content-blocks/p-9058031c.entry.js +1 -0
- package/dist/content-blocks/p-9c41ac23.entry.js +17 -0
- package/dist/content-blocks/p-CLwOzPEO.js +3 -0
- package/dist/content-blocks/p-CYF5GU_q.js +1 -0
- package/dist/content-blocks/p-CjR_4mPu.js +1 -0
- package/dist/content-blocks/p-DQuL1Twl.js +1 -0
- package/dist/content-blocks/p-DXUoPIwl.js +10 -0
- package/dist/content-blocks/p-D_Ll4QNj.js +1 -0
- package/dist/content-blocks/p-DhIoW7H3.js +1 -0
- package/dist/content-blocks/p-DzYwy_62.js +1 -0
- package/dist/content-blocks/p-b2e6358a.entry.js +1 -0
- package/dist/content-blocks/p-c783bc68.entry.js +1 -0
- package/dist/content-blocks/p-e3d81e15.entry.js +1 -0
- package/dist/content-blocks/p-f23b4aae.entry.js +1 -0
- package/dist/content-blocks/p-f75c9094.entry.js +1 -0
- package/dist/content-blocks/responsive-component-BsLrcKbS.js +169 -0
- package/dist/content-blocks/sass/_mixins.scss +21 -5
- package/dist/content-blocks/sass/_variables.scss +15 -15
- package/dist/{esm/swiper-e9621adb.js → content-blocks/swiper-nBv069TB.js} +268 -235
- package/dist/{components/p-b85cfa86.js → content-blocks/utils--SDsQnWS.js} +51 -50
- package/dist/content-blocks/utils-Bak__24s.js +280 -0
- package/dist/docs.d.ts +480 -0
- package/dist/docs.json +5312 -0
- package/dist/esm/{app-globals-0f993ce5.js → app-globals-DQuL1Twl.js} +0 -2
- package/dist/esm/content-accordion.entry.js +85 -0
- package/dist/esm/content-blocks.js +33 -8
- package/dist/esm/content-button.entry.js +111 -0
- package/dist/esm/content-carousel.entry.js +153 -45
- package/dist/esm/content-grid-formatter.entry.js +100 -0
- package/dist/esm/content-hero-block.entry.js +43 -0
- package/dist/esm/content-image.entry.js +151 -0
- package/dist/esm/content-line.entry.js +59 -0
- package/dist/esm/content-navigation-block.entry.js +51 -32
- package/dist/esm/content-overlay.entry.js +639 -0
- package/dist/esm/content-spacer.entry.js +73 -0
- package/dist/esm/content-split-block.entry.js +22 -17
- package/dist/esm/content-tabs.entry.js +38 -19
- package/dist/esm/content-text-block.entry.js +61 -0
- package/dist/esm/content-tout-block.entry.js +32 -0
- package/dist/esm/content-video.entry.js +72033 -0
- package/dist/esm/focus-trap.esm-DXUoPIwl.js +1801 -0
- package/dist/esm/index-BASCLGuP.js +1713 -0
- package/dist/esm/index-BFDJMblF.js +4690 -0
- package/dist/esm/index-CLwOzPEO.js +2161 -0
- package/dist/esm/index-CjR_4mPu.js +280 -0
- package/dist/esm/index-P1YnSd-O.js +5397 -0
- package/dist/esm/index.js +1 -3
- package/dist/esm/loader.js +3 -6
- package/dist/esm/responsive-component-BsLrcKbS.js +169 -0
- package/dist/esm/responsive-component-D7dJHMp0.js +169 -0
- package/dist/esm/swiper-CtypHPwF.js +3928 -0
- package/dist/esm/swiper-nBv069TB.js +3941 -0
- package/dist/esm/utils--SDsQnWS.js +460 -0
- package/dist/esm/utils-Bak__24s.js +280 -0
- package/dist/esm/utils-CYF5GU_q.js +438 -0
- package/dist/node_modules/video.js/dist/video-js.min.css +1 -0
- package/dist/test/axe.js +60 -0
- package/dist/types/Users/shahrukceo/Developer/content-blocks/packages/js/.stencil/test/axe.d.ts +16 -0
- package/dist/types/blocks/content-hero-block/content-hero-block.d.ts +7 -11
- package/dist/types/blocks/content-split-block/content-split-block.d.ts +5 -9
- package/dist/types/blocks/content-text-block/content-text-block.d.ts +4 -9
- package/dist/types/blocks/content-tout-block/content-tout-block.d.ts +5 -10
- package/dist/types/components/content-accordion/content-accordion.d.ts +4 -3
- package/dist/types/components/content-accordion/libraries/w3_disclosure_button.d.ts +0 -1
- package/dist/types/components/content-carousel/content-carousel.d.ts +44 -7
- package/dist/types/components/content-navigation-block/content-navigation-block.d.ts +14 -8
- package/dist/types/components/content-overlay/content-overlay.d.ts +15 -16
- package/dist/types/components/content-overlay/libraries/aria-dialog.d.ts +0 -1
- package/dist/types/components/content-overlay/libraries/aria-utilities.d.ts +0 -1
- package/dist/types/components/content-tabs/content-tabs.d.ts +4 -10
- package/dist/types/components/content-tabs/libraries/w3_tabs.d.ts +0 -1
- package/dist/types/components.d.ts +900 -196
- package/dist/types/elements/content-button/content-button.d.ts +8 -13
- package/dist/types/elements/content-image/content-image.d.ts +15 -9
- package/dist/types/elements/content-line/content-line.d.ts +5 -12
- package/dist/types/elements/content-video/content-video.d.ts +12 -11
- package/dist/types/formatters/content-grid-formatter/content-grid-formatter.d.ts +14 -9
- package/dist/types/formatters/content-spacer/content-spacer.d.ts +4 -36
- package/dist/types/index.d.ts +3 -1
- package/dist/types/setupFiles.d.ts +0 -1
- package/dist/types/stencil-public-runtime.d.ts +265 -60
- package/dist/types/typings.d.ts +10 -0
- package/dist/types/utils/breakpoints.d.ts +57 -0
- package/dist/types/utils/responsive-component.d.ts +49 -0
- package/dist/types/utils/utils.d.ts +11 -8
- package/loader/cdn.js +1 -0
- package/loader/index.cjs.js +1 -0
- package/loader/index.d.ts +24 -0
- package/loader/index.es2017.js +1 -0
- package/loader/index.js +2 -0
- package/package.json +75 -65
- package/dist/cjs/BehaviorSubject-12116537.js +0 -655
- package/dist/cjs/BehaviorSubject-12116537.js.map +0 -1
- package/dist/cjs/app-globals-3a1e7e63.js.map +0 -1
- package/dist/cjs/content-accordion_11.cjs.entry.js.map +0 -1
- package/dist/cjs/content-blocks.cjs.js.map +0 -1
- package/dist/cjs/content-carousel.cjs.entry.js.map +0 -1
- package/dist/cjs/content-navigation-block.cjs.entry.js.map +0 -1
- package/dist/cjs/content-split-block.cjs.entry.js.map +0 -1
- package/dist/cjs/content-tabs.cjs.entry.js.map +0 -1
- package/dist/cjs/focus-trap.esm-7bc384a0.js.map +0 -1
- package/dist/cjs/index-2e0ce692.js.map +0 -1
- package/dist/cjs/index-8af2820a.js +0 -1650
- package/dist/cjs/index-8af2820a.js.map +0 -1
- package/dist/cjs/index.cjs.js.map +0 -1
- package/dist/cjs/loader.cjs.js.map +0 -1
- package/dist/cjs/swiper-8221f4e8.js.map +0 -1
- package/dist/cjs/utils-df044337.js.map +0 -1
- package/dist/cjs/utils-f8ccab0a.js +0 -126
- package/dist/cjs/utils-f8ccab0a.js.map +0 -1
- package/dist/cjs/window-resize-service-65a5a370.js +0 -37
- package/dist/cjs/window-resize-service-65a5a370.js.map +0 -1
- package/dist/collection/blocks/content-hero-block/content-hero-block.js.map +0 -1
- package/dist/collection/blocks/content-split-block/content-split-block.js.map +0 -1
- package/dist/collection/blocks/content-text-block/content-text-block.js.map +0 -1
- package/dist/collection/blocks/content-tout-block/content-tout-block.js.map +0 -1
- package/dist/collection/components/content-accordion/content-accordion.js.map +0 -1
- package/dist/collection/components/content-accordion/libraries/w3_disclosure_button.js.map +0 -1
- package/dist/collection/components/content-carousel/content-carousel.js.map +0 -1
- package/dist/collection/components/content-navigation-block/content-navigation-block.js.map +0 -1
- package/dist/collection/components/content-overlay/content-overlay.js.map +0 -1
- package/dist/collection/components/content-overlay/libraries/aria-dialog.js.map +0 -1
- package/dist/collection/components/content-overlay/libraries/aria-utilities.js.map +0 -1
- package/dist/collection/components/content-tabs/content-tabs.js.map +0 -1
- package/dist/collection/components/content-tabs/libraries/w3_tabs.js.map +0 -1
- package/dist/collection/elements/content-button/content-button.js.map +0 -1
- package/dist/collection/elements/content-image/content-image.js.map +0 -1
- package/dist/collection/elements/content-line/content-line.js.map +0 -1
- package/dist/collection/elements/content-video/content-video.js.map +0 -1
- package/dist/collection/formatters/content-grid-formatter/content-grid-formatter.js.map +0 -1
- package/dist/collection/formatters/content-spacer/content-spacer.js.map +0 -1
- package/dist/collection/globalScript.js +0 -15
- package/dist/collection/globalScript.js.map +0 -1
- package/dist/collection/index.js.map +0 -1
- package/dist/collection/services/content-events-service.js +0 -23
- package/dist/collection/services/content-events-service.js.map +0 -1
- package/dist/collection/services/window-resize-service.js +0 -31
- package/dist/collection/services/window-resize-service.js.map +0 -1
- package/dist/collection/setupFiles.js.map +0 -1
- package/dist/collection/stories/ContentHeroBlock.stories.js +0 -51
- package/dist/collection/stories/ContentHeroBlock.stories.js.map +0 -1
- package/dist/collection/stories/ContentNavigationBlock.stories.js +0 -33
- package/dist/collection/stories/ContentNavigationBlock.stories.js.map +0 -1
- package/dist/collection/stories/ContentSpacer.stories.js +0 -20
- package/dist/collection/stories/ContentSpacer.stories.js.map +0 -1
- package/dist/collection/stories/ContentTextBlock.stories.js +0 -17
- package/dist/collection/stories/ContentTextBlock.stories.js.map +0 -1
- package/dist/collection/stories/ContentToutBlock.stories.js +0 -17
- package/dist/collection/stories/ContentToutBlock.stories.js.map +0 -1
- package/dist/collection/stories/FullPageExample.stories.js +0 -432
- package/dist/collection/stories/FullPageExample.stories.js.map +0 -1
- package/dist/collection/stories/assets/accessibility.svg +0 -5
- package/dist/collection/stories/assets/discord.svg +0 -15
- package/dist/collection/stories/assets/github.svg +0 -3
- package/dist/collection/stories/assets/tutorials.svg +0 -12
- package/dist/collection/stories/assets/youtube.svg +0 -4
- package/dist/collection/utils/utils.js.map +0 -1
- package/dist/components/content-accordion.js.map +0 -1
- package/dist/components/content-button.js.map +0 -1
- package/dist/components/content-carousel.js.map +0 -1
- package/dist/components/content-grid-formatter.js.map +0 -1
- package/dist/components/content-hero-block.js.map +0 -1
- package/dist/components/content-image.js.map +0 -1
- package/dist/components/content-line.js.map +0 -1
- package/dist/components/content-navigation-block.js.map +0 -1
- package/dist/components/content-overlay.js.map +0 -1
- package/dist/components/content-spacer.js.map +0 -1
- package/dist/components/content-split-block.js.map +0 -1
- package/dist/components/content-tabs.js.map +0 -1
- package/dist/components/content-text-block.js.map +0 -1
- package/dist/components/content-tout-block.js.map +0 -1
- package/dist/components/content-video.js.map +0 -1
- package/dist/components/index.js.map +0 -1
- package/dist/components/p-26483b46.js +0 -35
- package/dist/components/p-26483b46.js.map +0 -1
- package/dist/components/p-5a91aa1b.js.map +0 -1
- package/dist/components/p-74be971f.js +0 -652
- package/dist/components/p-74be971f.js.map +0 -1
- package/dist/components/p-7a436263.js +0 -122
- package/dist/components/p-7a436263.js.map +0 -1
- package/dist/components/p-a2fedf8a.js.map +0 -1
- package/dist/components/p-b85cfa86.js.map +0 -1
- package/dist/components/p-e28db040.js +0 -1452
- package/dist/components/p-e28db040.js.map +0 -1
- package/dist/components/p-e5dc4ea4.js.map +0 -1
- package/dist/components/p-e9bce2ab.js +0 -88
- package/dist/components/p-e9bce2ab.js.map +0 -1
- package/dist/content-blocks/content-blocks.esm.js.map +0 -1
- package/dist/content-blocks/index.esm.js.map +0 -1
- package/dist/content-blocks/p-13c3cc4f.js +0 -3
- package/dist/content-blocks/p-13c3cc4f.js.map +0 -1
- package/dist/content-blocks/p-5422c25b.entry.js +0 -2
- package/dist/content-blocks/p-5422c25b.entry.js.map +0 -1
- package/dist/content-blocks/p-5a91aa1b.js +0 -2
- package/dist/content-blocks/p-5a91aa1b.js.map +0 -1
- package/dist/content-blocks/p-650d1757.js +0 -2
- package/dist/content-blocks/p-650d1757.js.map +0 -1
- package/dist/content-blocks/p-74be971f.js +0 -2
- package/dist/content-blocks/p-74be971f.js.map +0 -1
- package/dist/content-blocks/p-8deb755c.entry.js +0 -26
- package/dist/content-blocks/p-8deb755c.entry.js.map +0 -1
- package/dist/content-blocks/p-a2fedf8a.js +0 -10
- package/dist/content-blocks/p-a2fedf8a.js.map +0 -1
- package/dist/content-blocks/p-b305392e.entry.js +0 -2
- package/dist/content-blocks/p-b305392e.entry.js.map +0 -1
- package/dist/content-blocks/p-b85cfa86.js +0 -2
- package/dist/content-blocks/p-b85cfa86.js.map +0 -1
- package/dist/content-blocks/p-cc7397cf.js +0 -2
- package/dist/content-blocks/p-cc7397cf.js.map +0 -1
- package/dist/content-blocks/p-d62775d7.entry.js +0 -2
- package/dist/content-blocks/p-d62775d7.entry.js.map +0 -1
- package/dist/content-blocks/p-e1255160.js +0 -2
- package/dist/content-blocks/p-e1255160.js.map +0 -1
- package/dist/content-blocks/p-e5dc4ea4.js +0 -2
- package/dist/content-blocks/p-e5dc4ea4.js.map +0 -1
- package/dist/content-blocks/p-f73f934a.entry.js +0 -2
- package/dist/content-blocks/p-f73f934a.entry.js.map +0 -1
- package/dist/esm/BehaviorSubject-f7a12fd8.js +0 -652
- package/dist/esm/BehaviorSubject-f7a12fd8.js.map +0 -1
- package/dist/esm/app-globals-0f993ce5.js.map +0 -1
- package/dist/esm/content-accordion_11.entry.js.map +0 -1
- package/dist/esm/content-blocks.js.map +0 -1
- package/dist/esm/content-carousel.entry.js.map +0 -1
- package/dist/esm/content-navigation-block.entry.js.map +0 -1
- package/dist/esm/content-split-block.entry.js.map +0 -1
- package/dist/esm/content-tabs.entry.js.map +0 -1
- package/dist/esm/focus-trap.esm-8fb54175.js.map +0 -1
- package/dist/esm/index-ec24af7a.js +0 -1621
- package/dist/esm/index-ec24af7a.js.map +0 -1
- package/dist/esm/index-f45a9c45.js.map +0 -1
- package/dist/esm/index.js.map +0 -1
- package/dist/esm/loader.js.map +0 -1
- package/dist/esm/swiper-e9621adb.js.map +0 -1
- package/dist/esm/utils-1c9f0ec1.js.map +0 -1
- package/dist/esm/utils-9a901aa9.js +0 -122
- package/dist/esm/utils-9a901aa9.js.map +0 -1
- package/dist/esm/window-resize-service-354f2ac5.js +0 -35
- package/dist/esm/window-resize-service-354f2ac5.js.map +0 -1
- package/dist/types/globalScript.d.ts +0 -1
- package/dist/types/old-components.d.ts +0 -1239
- package/dist/types/services/content-events-service.d.ts +0 -11
- package/dist/types/services/window-resize-service.d.ts +0 -11
- package/dist/types/stories/ContentHeroBlock.stories.d.ts +0 -11
- package/dist/types/stories/ContentNavigationBlock.stories.d.ts +0 -9
- package/dist/types/stories/ContentSpacer.stories.d.ts +0 -15
- package/dist/types/stories/ContentTextBlock.stories.d.ts +0 -9
- package/dist/types/stories/ContentToutBlock.stories.d.ts +0 -9
- package/dist/types/stories/FullPageExample.stories.d.ts +0 -10
|
@@ -1,652 +0,0 @@
|
|
|
1
|
-
function isFunction(value) {
|
|
2
|
-
return typeof value === 'function';
|
|
3
|
-
}
|
|
4
|
-
|
|
5
|
-
function createErrorClass(createImpl) {
|
|
6
|
-
const _super = (instance) => {
|
|
7
|
-
Error.call(instance);
|
|
8
|
-
instance.stack = new Error().stack;
|
|
9
|
-
};
|
|
10
|
-
const ctorFunc = createImpl(_super);
|
|
11
|
-
ctorFunc.prototype = Object.create(Error.prototype);
|
|
12
|
-
ctorFunc.prototype.constructor = ctorFunc;
|
|
13
|
-
return ctorFunc;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
const UnsubscriptionError = createErrorClass((_super) => function UnsubscriptionErrorImpl(errors) {
|
|
17
|
-
_super(this);
|
|
18
|
-
this.message = errors
|
|
19
|
-
? `${errors.length} errors occurred during unsubscription:
|
|
20
|
-
${errors.map((err, i) => `${i + 1}) ${err.toString()}`).join('\n ')}`
|
|
21
|
-
: '';
|
|
22
|
-
this.name = 'UnsubscriptionError';
|
|
23
|
-
this.errors = errors;
|
|
24
|
-
});
|
|
25
|
-
|
|
26
|
-
function arrRemove(arr, item) {
|
|
27
|
-
if (arr) {
|
|
28
|
-
const index = arr.indexOf(item);
|
|
29
|
-
0 <= index && arr.splice(index, 1);
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
class Subscription {
|
|
34
|
-
constructor(initialTeardown) {
|
|
35
|
-
this.initialTeardown = initialTeardown;
|
|
36
|
-
this.closed = false;
|
|
37
|
-
this._parentage = null;
|
|
38
|
-
this._finalizers = null;
|
|
39
|
-
}
|
|
40
|
-
unsubscribe() {
|
|
41
|
-
let errors;
|
|
42
|
-
if (!this.closed) {
|
|
43
|
-
this.closed = true;
|
|
44
|
-
const { _parentage } = this;
|
|
45
|
-
if (_parentage) {
|
|
46
|
-
this._parentage = null;
|
|
47
|
-
if (Array.isArray(_parentage)) {
|
|
48
|
-
for (const parent of _parentage) {
|
|
49
|
-
parent.remove(this);
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
else {
|
|
53
|
-
_parentage.remove(this);
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
|
-
const { initialTeardown: initialFinalizer } = this;
|
|
57
|
-
if (isFunction(initialFinalizer)) {
|
|
58
|
-
try {
|
|
59
|
-
initialFinalizer();
|
|
60
|
-
}
|
|
61
|
-
catch (e) {
|
|
62
|
-
errors = e instanceof UnsubscriptionError ? e.errors : [e];
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
const { _finalizers } = this;
|
|
66
|
-
if (_finalizers) {
|
|
67
|
-
this._finalizers = null;
|
|
68
|
-
for (const finalizer of _finalizers) {
|
|
69
|
-
try {
|
|
70
|
-
execFinalizer(finalizer);
|
|
71
|
-
}
|
|
72
|
-
catch (err) {
|
|
73
|
-
errors = errors !== null && errors !== void 0 ? errors : [];
|
|
74
|
-
if (err instanceof UnsubscriptionError) {
|
|
75
|
-
errors = [...errors, ...err.errors];
|
|
76
|
-
}
|
|
77
|
-
else {
|
|
78
|
-
errors.push(err);
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
if (errors) {
|
|
84
|
-
throw new UnsubscriptionError(errors);
|
|
85
|
-
}
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
add(teardown) {
|
|
89
|
-
var _a;
|
|
90
|
-
if (teardown && teardown !== this) {
|
|
91
|
-
if (this.closed) {
|
|
92
|
-
execFinalizer(teardown);
|
|
93
|
-
}
|
|
94
|
-
else {
|
|
95
|
-
if (teardown instanceof Subscription) {
|
|
96
|
-
if (teardown.closed || teardown._hasParent(this)) {
|
|
97
|
-
return;
|
|
98
|
-
}
|
|
99
|
-
teardown._addParent(this);
|
|
100
|
-
}
|
|
101
|
-
(this._finalizers = (_a = this._finalizers) !== null && _a !== void 0 ? _a : []).push(teardown);
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
|
-
}
|
|
105
|
-
_hasParent(parent) {
|
|
106
|
-
const { _parentage } = this;
|
|
107
|
-
return _parentage === parent || (Array.isArray(_parentage) && _parentage.includes(parent));
|
|
108
|
-
}
|
|
109
|
-
_addParent(parent) {
|
|
110
|
-
const { _parentage } = this;
|
|
111
|
-
this._parentage = Array.isArray(_parentage) ? (_parentage.push(parent), _parentage) : _parentage ? [_parentage, parent] : parent;
|
|
112
|
-
}
|
|
113
|
-
_removeParent(parent) {
|
|
114
|
-
const { _parentage } = this;
|
|
115
|
-
if (_parentage === parent) {
|
|
116
|
-
this._parentage = null;
|
|
117
|
-
}
|
|
118
|
-
else if (Array.isArray(_parentage)) {
|
|
119
|
-
arrRemove(_parentage, parent);
|
|
120
|
-
}
|
|
121
|
-
}
|
|
122
|
-
remove(teardown) {
|
|
123
|
-
const { _finalizers } = this;
|
|
124
|
-
_finalizers && arrRemove(_finalizers, teardown);
|
|
125
|
-
if (teardown instanceof Subscription) {
|
|
126
|
-
teardown._removeParent(this);
|
|
127
|
-
}
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
|
-
Subscription.EMPTY = (() => {
|
|
131
|
-
const empty = new Subscription();
|
|
132
|
-
empty.closed = true;
|
|
133
|
-
return empty;
|
|
134
|
-
})();
|
|
135
|
-
const EMPTY_SUBSCRIPTION = Subscription.EMPTY;
|
|
136
|
-
function isSubscription(value) {
|
|
137
|
-
return (value instanceof Subscription ||
|
|
138
|
-
(value && 'closed' in value && isFunction(value.remove) && isFunction(value.add) && isFunction(value.unsubscribe)));
|
|
139
|
-
}
|
|
140
|
-
function execFinalizer(finalizer) {
|
|
141
|
-
if (isFunction(finalizer)) {
|
|
142
|
-
finalizer();
|
|
143
|
-
}
|
|
144
|
-
else {
|
|
145
|
-
finalizer.unsubscribe();
|
|
146
|
-
}
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
const config = {
|
|
150
|
-
onUnhandledError: null,
|
|
151
|
-
onStoppedNotification: null,
|
|
152
|
-
Promise: undefined,
|
|
153
|
-
useDeprecatedSynchronousErrorHandling: false,
|
|
154
|
-
useDeprecatedNextContext: false,
|
|
155
|
-
};
|
|
156
|
-
|
|
157
|
-
const timeoutProvider = {
|
|
158
|
-
setTimeout(handler, timeout, ...args) {
|
|
159
|
-
const { delegate } = timeoutProvider;
|
|
160
|
-
if (delegate === null || delegate === void 0 ? void 0 : delegate.setTimeout) {
|
|
161
|
-
return delegate.setTimeout(handler, timeout, ...args);
|
|
162
|
-
}
|
|
163
|
-
return setTimeout(handler, timeout, ...args);
|
|
164
|
-
},
|
|
165
|
-
clearTimeout(handle) {
|
|
166
|
-
const { delegate } = timeoutProvider;
|
|
167
|
-
return ((delegate === null || delegate === void 0 ? void 0 : delegate.clearTimeout) || clearTimeout)(handle);
|
|
168
|
-
},
|
|
169
|
-
delegate: undefined,
|
|
170
|
-
};
|
|
171
|
-
|
|
172
|
-
function reportUnhandledError(err) {
|
|
173
|
-
timeoutProvider.setTimeout(() => {
|
|
174
|
-
const { onUnhandledError } = config;
|
|
175
|
-
if (onUnhandledError) {
|
|
176
|
-
onUnhandledError(err);
|
|
177
|
-
}
|
|
178
|
-
else {
|
|
179
|
-
throw err;
|
|
180
|
-
}
|
|
181
|
-
});
|
|
182
|
-
}
|
|
183
|
-
|
|
184
|
-
function noop() { }
|
|
185
|
-
|
|
186
|
-
const COMPLETE_NOTIFICATION = (() => createNotification('C', undefined, undefined))();
|
|
187
|
-
function errorNotification(error) {
|
|
188
|
-
return createNotification('E', undefined, error);
|
|
189
|
-
}
|
|
190
|
-
function nextNotification(value) {
|
|
191
|
-
return createNotification('N', value, undefined);
|
|
192
|
-
}
|
|
193
|
-
function createNotification(kind, value, error) {
|
|
194
|
-
return {
|
|
195
|
-
kind,
|
|
196
|
-
value,
|
|
197
|
-
error,
|
|
198
|
-
};
|
|
199
|
-
}
|
|
200
|
-
|
|
201
|
-
let context = null;
|
|
202
|
-
function errorContext(cb) {
|
|
203
|
-
if (config.useDeprecatedSynchronousErrorHandling) {
|
|
204
|
-
const isRoot = !context;
|
|
205
|
-
if (isRoot) {
|
|
206
|
-
context = { errorThrown: false, error: null };
|
|
207
|
-
}
|
|
208
|
-
cb();
|
|
209
|
-
if (isRoot) {
|
|
210
|
-
const { errorThrown, error } = context;
|
|
211
|
-
context = null;
|
|
212
|
-
if (errorThrown) {
|
|
213
|
-
throw error;
|
|
214
|
-
}
|
|
215
|
-
}
|
|
216
|
-
}
|
|
217
|
-
else {
|
|
218
|
-
cb();
|
|
219
|
-
}
|
|
220
|
-
}
|
|
221
|
-
|
|
222
|
-
class Subscriber extends Subscription {
|
|
223
|
-
constructor(destination) {
|
|
224
|
-
super();
|
|
225
|
-
this.isStopped = false;
|
|
226
|
-
if (destination) {
|
|
227
|
-
this.destination = destination;
|
|
228
|
-
if (isSubscription(destination)) {
|
|
229
|
-
destination.add(this);
|
|
230
|
-
}
|
|
231
|
-
}
|
|
232
|
-
else {
|
|
233
|
-
this.destination = EMPTY_OBSERVER;
|
|
234
|
-
}
|
|
235
|
-
}
|
|
236
|
-
static create(next, error, complete) {
|
|
237
|
-
return new SafeSubscriber(next, error, complete);
|
|
238
|
-
}
|
|
239
|
-
next(value) {
|
|
240
|
-
if (this.isStopped) {
|
|
241
|
-
handleStoppedNotification(nextNotification(value), this);
|
|
242
|
-
}
|
|
243
|
-
else {
|
|
244
|
-
this._next(value);
|
|
245
|
-
}
|
|
246
|
-
}
|
|
247
|
-
error(err) {
|
|
248
|
-
if (this.isStopped) {
|
|
249
|
-
handleStoppedNotification(errorNotification(err), this);
|
|
250
|
-
}
|
|
251
|
-
else {
|
|
252
|
-
this.isStopped = true;
|
|
253
|
-
this._error(err);
|
|
254
|
-
}
|
|
255
|
-
}
|
|
256
|
-
complete() {
|
|
257
|
-
if (this.isStopped) {
|
|
258
|
-
handleStoppedNotification(COMPLETE_NOTIFICATION, this);
|
|
259
|
-
}
|
|
260
|
-
else {
|
|
261
|
-
this.isStopped = true;
|
|
262
|
-
this._complete();
|
|
263
|
-
}
|
|
264
|
-
}
|
|
265
|
-
unsubscribe() {
|
|
266
|
-
if (!this.closed) {
|
|
267
|
-
this.isStopped = true;
|
|
268
|
-
super.unsubscribe();
|
|
269
|
-
this.destination = null;
|
|
270
|
-
}
|
|
271
|
-
}
|
|
272
|
-
_next(value) {
|
|
273
|
-
this.destination.next(value);
|
|
274
|
-
}
|
|
275
|
-
_error(err) {
|
|
276
|
-
try {
|
|
277
|
-
this.destination.error(err);
|
|
278
|
-
}
|
|
279
|
-
finally {
|
|
280
|
-
this.unsubscribe();
|
|
281
|
-
}
|
|
282
|
-
}
|
|
283
|
-
_complete() {
|
|
284
|
-
try {
|
|
285
|
-
this.destination.complete();
|
|
286
|
-
}
|
|
287
|
-
finally {
|
|
288
|
-
this.unsubscribe();
|
|
289
|
-
}
|
|
290
|
-
}
|
|
291
|
-
}
|
|
292
|
-
const _bind = Function.prototype.bind;
|
|
293
|
-
function bind(fn, thisArg) {
|
|
294
|
-
return _bind.call(fn, thisArg);
|
|
295
|
-
}
|
|
296
|
-
class ConsumerObserver {
|
|
297
|
-
constructor(partialObserver) {
|
|
298
|
-
this.partialObserver = partialObserver;
|
|
299
|
-
}
|
|
300
|
-
next(value) {
|
|
301
|
-
const { partialObserver } = this;
|
|
302
|
-
if (partialObserver.next) {
|
|
303
|
-
try {
|
|
304
|
-
partialObserver.next(value);
|
|
305
|
-
}
|
|
306
|
-
catch (error) {
|
|
307
|
-
handleUnhandledError(error);
|
|
308
|
-
}
|
|
309
|
-
}
|
|
310
|
-
}
|
|
311
|
-
error(err) {
|
|
312
|
-
const { partialObserver } = this;
|
|
313
|
-
if (partialObserver.error) {
|
|
314
|
-
try {
|
|
315
|
-
partialObserver.error(err);
|
|
316
|
-
}
|
|
317
|
-
catch (error) {
|
|
318
|
-
handleUnhandledError(error);
|
|
319
|
-
}
|
|
320
|
-
}
|
|
321
|
-
else {
|
|
322
|
-
handleUnhandledError(err);
|
|
323
|
-
}
|
|
324
|
-
}
|
|
325
|
-
complete() {
|
|
326
|
-
const { partialObserver } = this;
|
|
327
|
-
if (partialObserver.complete) {
|
|
328
|
-
try {
|
|
329
|
-
partialObserver.complete();
|
|
330
|
-
}
|
|
331
|
-
catch (error) {
|
|
332
|
-
handleUnhandledError(error);
|
|
333
|
-
}
|
|
334
|
-
}
|
|
335
|
-
}
|
|
336
|
-
}
|
|
337
|
-
class SafeSubscriber extends Subscriber {
|
|
338
|
-
constructor(observerOrNext, error, complete) {
|
|
339
|
-
super();
|
|
340
|
-
let partialObserver;
|
|
341
|
-
if (isFunction(observerOrNext) || !observerOrNext) {
|
|
342
|
-
partialObserver = {
|
|
343
|
-
next: (observerOrNext !== null && observerOrNext !== void 0 ? observerOrNext : undefined),
|
|
344
|
-
error: error !== null && error !== void 0 ? error : undefined,
|
|
345
|
-
complete: complete !== null && complete !== void 0 ? complete : undefined,
|
|
346
|
-
};
|
|
347
|
-
}
|
|
348
|
-
else {
|
|
349
|
-
let context;
|
|
350
|
-
if (this && config.useDeprecatedNextContext) {
|
|
351
|
-
context = Object.create(observerOrNext);
|
|
352
|
-
context.unsubscribe = () => this.unsubscribe();
|
|
353
|
-
partialObserver = {
|
|
354
|
-
next: observerOrNext.next && bind(observerOrNext.next, context),
|
|
355
|
-
error: observerOrNext.error && bind(observerOrNext.error, context),
|
|
356
|
-
complete: observerOrNext.complete && bind(observerOrNext.complete, context),
|
|
357
|
-
};
|
|
358
|
-
}
|
|
359
|
-
else {
|
|
360
|
-
partialObserver = observerOrNext;
|
|
361
|
-
}
|
|
362
|
-
}
|
|
363
|
-
this.destination = new ConsumerObserver(partialObserver);
|
|
364
|
-
}
|
|
365
|
-
}
|
|
366
|
-
function handleUnhandledError(error) {
|
|
367
|
-
{
|
|
368
|
-
reportUnhandledError(error);
|
|
369
|
-
}
|
|
370
|
-
}
|
|
371
|
-
function defaultErrorHandler(err) {
|
|
372
|
-
throw err;
|
|
373
|
-
}
|
|
374
|
-
function handleStoppedNotification(notification, subscriber) {
|
|
375
|
-
const { onStoppedNotification } = config;
|
|
376
|
-
onStoppedNotification && timeoutProvider.setTimeout(() => onStoppedNotification(notification, subscriber));
|
|
377
|
-
}
|
|
378
|
-
const EMPTY_OBSERVER = {
|
|
379
|
-
closed: true,
|
|
380
|
-
next: noop,
|
|
381
|
-
error: defaultErrorHandler,
|
|
382
|
-
complete: noop,
|
|
383
|
-
};
|
|
384
|
-
|
|
385
|
-
const observable = (() => (typeof Symbol === 'function' && Symbol.observable) || '@@observable')();
|
|
386
|
-
|
|
387
|
-
function identity(x) {
|
|
388
|
-
return x;
|
|
389
|
-
}
|
|
390
|
-
|
|
391
|
-
function pipeFromArray(fns) {
|
|
392
|
-
if (fns.length === 0) {
|
|
393
|
-
return identity;
|
|
394
|
-
}
|
|
395
|
-
if (fns.length === 1) {
|
|
396
|
-
return fns[0];
|
|
397
|
-
}
|
|
398
|
-
return function piped(input) {
|
|
399
|
-
return fns.reduce((prev, fn) => fn(prev), input);
|
|
400
|
-
};
|
|
401
|
-
}
|
|
402
|
-
|
|
403
|
-
class Observable {
|
|
404
|
-
constructor(subscribe) {
|
|
405
|
-
if (subscribe) {
|
|
406
|
-
this._subscribe = subscribe;
|
|
407
|
-
}
|
|
408
|
-
}
|
|
409
|
-
lift(operator) {
|
|
410
|
-
const observable = new Observable();
|
|
411
|
-
observable.source = this;
|
|
412
|
-
observable.operator = operator;
|
|
413
|
-
return observable;
|
|
414
|
-
}
|
|
415
|
-
subscribe(observerOrNext, error, complete) {
|
|
416
|
-
const subscriber = isSubscriber(observerOrNext) ? observerOrNext : new SafeSubscriber(observerOrNext, error, complete);
|
|
417
|
-
errorContext(() => {
|
|
418
|
-
const { operator, source } = this;
|
|
419
|
-
subscriber.add(operator
|
|
420
|
-
?
|
|
421
|
-
operator.call(subscriber, source)
|
|
422
|
-
: source
|
|
423
|
-
?
|
|
424
|
-
this._subscribe(subscriber)
|
|
425
|
-
:
|
|
426
|
-
this._trySubscribe(subscriber));
|
|
427
|
-
});
|
|
428
|
-
return subscriber;
|
|
429
|
-
}
|
|
430
|
-
_trySubscribe(sink) {
|
|
431
|
-
try {
|
|
432
|
-
return this._subscribe(sink);
|
|
433
|
-
}
|
|
434
|
-
catch (err) {
|
|
435
|
-
sink.error(err);
|
|
436
|
-
}
|
|
437
|
-
}
|
|
438
|
-
forEach(next, promiseCtor) {
|
|
439
|
-
promiseCtor = getPromiseCtor(promiseCtor);
|
|
440
|
-
return new promiseCtor((resolve, reject) => {
|
|
441
|
-
const subscriber = new SafeSubscriber({
|
|
442
|
-
next: (value) => {
|
|
443
|
-
try {
|
|
444
|
-
next(value);
|
|
445
|
-
}
|
|
446
|
-
catch (err) {
|
|
447
|
-
reject(err);
|
|
448
|
-
subscriber.unsubscribe();
|
|
449
|
-
}
|
|
450
|
-
},
|
|
451
|
-
error: reject,
|
|
452
|
-
complete: resolve,
|
|
453
|
-
});
|
|
454
|
-
this.subscribe(subscriber);
|
|
455
|
-
});
|
|
456
|
-
}
|
|
457
|
-
_subscribe(subscriber) {
|
|
458
|
-
var _a;
|
|
459
|
-
return (_a = this.source) === null || _a === void 0 ? void 0 : _a.subscribe(subscriber);
|
|
460
|
-
}
|
|
461
|
-
[observable]() {
|
|
462
|
-
return this;
|
|
463
|
-
}
|
|
464
|
-
pipe(...operations) {
|
|
465
|
-
return pipeFromArray(operations)(this);
|
|
466
|
-
}
|
|
467
|
-
toPromise(promiseCtor) {
|
|
468
|
-
promiseCtor = getPromiseCtor(promiseCtor);
|
|
469
|
-
return new promiseCtor((resolve, reject) => {
|
|
470
|
-
let value;
|
|
471
|
-
this.subscribe((x) => (value = x), (err) => reject(err), () => resolve(value));
|
|
472
|
-
});
|
|
473
|
-
}
|
|
474
|
-
}
|
|
475
|
-
Observable.create = (subscribe) => {
|
|
476
|
-
return new Observable(subscribe);
|
|
477
|
-
};
|
|
478
|
-
function getPromiseCtor(promiseCtor) {
|
|
479
|
-
var _a;
|
|
480
|
-
return (_a = promiseCtor !== null && promiseCtor !== void 0 ? promiseCtor : config.Promise) !== null && _a !== void 0 ? _a : Promise;
|
|
481
|
-
}
|
|
482
|
-
function isObserver(value) {
|
|
483
|
-
return value && isFunction(value.next) && isFunction(value.error) && isFunction(value.complete);
|
|
484
|
-
}
|
|
485
|
-
function isSubscriber(value) {
|
|
486
|
-
return (value && value instanceof Subscriber) || (isObserver(value) && isSubscription(value));
|
|
487
|
-
}
|
|
488
|
-
|
|
489
|
-
const ObjectUnsubscribedError = createErrorClass((_super) => function ObjectUnsubscribedErrorImpl() {
|
|
490
|
-
_super(this);
|
|
491
|
-
this.name = 'ObjectUnsubscribedError';
|
|
492
|
-
this.message = 'object unsubscribed';
|
|
493
|
-
});
|
|
494
|
-
|
|
495
|
-
class Subject extends Observable {
|
|
496
|
-
constructor() {
|
|
497
|
-
super();
|
|
498
|
-
this.closed = false;
|
|
499
|
-
this.currentObservers = null;
|
|
500
|
-
this.observers = [];
|
|
501
|
-
this.isStopped = false;
|
|
502
|
-
this.hasError = false;
|
|
503
|
-
this.thrownError = null;
|
|
504
|
-
}
|
|
505
|
-
lift(operator) {
|
|
506
|
-
const subject = new AnonymousSubject(this, this);
|
|
507
|
-
subject.operator = operator;
|
|
508
|
-
return subject;
|
|
509
|
-
}
|
|
510
|
-
_throwIfClosed() {
|
|
511
|
-
if (this.closed) {
|
|
512
|
-
throw new ObjectUnsubscribedError();
|
|
513
|
-
}
|
|
514
|
-
}
|
|
515
|
-
next(value) {
|
|
516
|
-
errorContext(() => {
|
|
517
|
-
this._throwIfClosed();
|
|
518
|
-
if (!this.isStopped) {
|
|
519
|
-
if (!this.currentObservers) {
|
|
520
|
-
this.currentObservers = Array.from(this.observers);
|
|
521
|
-
}
|
|
522
|
-
for (const observer of this.currentObservers) {
|
|
523
|
-
observer.next(value);
|
|
524
|
-
}
|
|
525
|
-
}
|
|
526
|
-
});
|
|
527
|
-
}
|
|
528
|
-
error(err) {
|
|
529
|
-
errorContext(() => {
|
|
530
|
-
this._throwIfClosed();
|
|
531
|
-
if (!this.isStopped) {
|
|
532
|
-
this.hasError = this.isStopped = true;
|
|
533
|
-
this.thrownError = err;
|
|
534
|
-
const { observers } = this;
|
|
535
|
-
while (observers.length) {
|
|
536
|
-
observers.shift().error(err);
|
|
537
|
-
}
|
|
538
|
-
}
|
|
539
|
-
});
|
|
540
|
-
}
|
|
541
|
-
complete() {
|
|
542
|
-
errorContext(() => {
|
|
543
|
-
this._throwIfClosed();
|
|
544
|
-
if (!this.isStopped) {
|
|
545
|
-
this.isStopped = true;
|
|
546
|
-
const { observers } = this;
|
|
547
|
-
while (observers.length) {
|
|
548
|
-
observers.shift().complete();
|
|
549
|
-
}
|
|
550
|
-
}
|
|
551
|
-
});
|
|
552
|
-
}
|
|
553
|
-
unsubscribe() {
|
|
554
|
-
this.isStopped = this.closed = true;
|
|
555
|
-
this.observers = this.currentObservers = null;
|
|
556
|
-
}
|
|
557
|
-
get observed() {
|
|
558
|
-
var _a;
|
|
559
|
-
return ((_a = this.observers) === null || _a === void 0 ? void 0 : _a.length) > 0;
|
|
560
|
-
}
|
|
561
|
-
_trySubscribe(subscriber) {
|
|
562
|
-
this._throwIfClosed();
|
|
563
|
-
return super._trySubscribe(subscriber);
|
|
564
|
-
}
|
|
565
|
-
_subscribe(subscriber) {
|
|
566
|
-
this._throwIfClosed();
|
|
567
|
-
this._checkFinalizedStatuses(subscriber);
|
|
568
|
-
return this._innerSubscribe(subscriber);
|
|
569
|
-
}
|
|
570
|
-
_innerSubscribe(subscriber) {
|
|
571
|
-
const { hasError, isStopped, observers } = this;
|
|
572
|
-
if (hasError || isStopped) {
|
|
573
|
-
return EMPTY_SUBSCRIPTION;
|
|
574
|
-
}
|
|
575
|
-
this.currentObservers = null;
|
|
576
|
-
observers.push(subscriber);
|
|
577
|
-
return new Subscription(() => {
|
|
578
|
-
this.currentObservers = null;
|
|
579
|
-
arrRemove(observers, subscriber);
|
|
580
|
-
});
|
|
581
|
-
}
|
|
582
|
-
_checkFinalizedStatuses(subscriber) {
|
|
583
|
-
const { hasError, thrownError, isStopped } = this;
|
|
584
|
-
if (hasError) {
|
|
585
|
-
subscriber.error(thrownError);
|
|
586
|
-
}
|
|
587
|
-
else if (isStopped) {
|
|
588
|
-
subscriber.complete();
|
|
589
|
-
}
|
|
590
|
-
}
|
|
591
|
-
asObservable() {
|
|
592
|
-
const observable = new Observable();
|
|
593
|
-
observable.source = this;
|
|
594
|
-
return observable;
|
|
595
|
-
}
|
|
596
|
-
}
|
|
597
|
-
Subject.create = (destination, source) => {
|
|
598
|
-
return new AnonymousSubject(destination, source);
|
|
599
|
-
};
|
|
600
|
-
class AnonymousSubject extends Subject {
|
|
601
|
-
constructor(destination, source) {
|
|
602
|
-
super();
|
|
603
|
-
this.destination = destination;
|
|
604
|
-
this.source = source;
|
|
605
|
-
}
|
|
606
|
-
next(value) {
|
|
607
|
-
var _a, _b;
|
|
608
|
-
(_b = (_a = this.destination) === null || _a === void 0 ? void 0 : _a.next) === null || _b === void 0 ? void 0 : _b.call(_a, value);
|
|
609
|
-
}
|
|
610
|
-
error(err) {
|
|
611
|
-
var _a, _b;
|
|
612
|
-
(_b = (_a = this.destination) === null || _a === void 0 ? void 0 : _a.error) === null || _b === void 0 ? void 0 : _b.call(_a, err);
|
|
613
|
-
}
|
|
614
|
-
complete() {
|
|
615
|
-
var _a, _b;
|
|
616
|
-
(_b = (_a = this.destination) === null || _a === void 0 ? void 0 : _a.complete) === null || _b === void 0 ? void 0 : _b.call(_a);
|
|
617
|
-
}
|
|
618
|
-
_subscribe(subscriber) {
|
|
619
|
-
var _a, _b;
|
|
620
|
-
return (_b = (_a = this.source) === null || _a === void 0 ? void 0 : _a.subscribe(subscriber)) !== null && _b !== void 0 ? _b : EMPTY_SUBSCRIPTION;
|
|
621
|
-
}
|
|
622
|
-
}
|
|
623
|
-
|
|
624
|
-
class BehaviorSubject extends Subject {
|
|
625
|
-
constructor(_value) {
|
|
626
|
-
super();
|
|
627
|
-
this._value = _value;
|
|
628
|
-
}
|
|
629
|
-
get value() {
|
|
630
|
-
return this.getValue();
|
|
631
|
-
}
|
|
632
|
-
_subscribe(subscriber) {
|
|
633
|
-
const subscription = super._subscribe(subscriber);
|
|
634
|
-
!subscription.closed && subscriber.next(this._value);
|
|
635
|
-
return subscription;
|
|
636
|
-
}
|
|
637
|
-
getValue() {
|
|
638
|
-
const { hasError, thrownError, _value } = this;
|
|
639
|
-
if (hasError) {
|
|
640
|
-
throw thrownError;
|
|
641
|
-
}
|
|
642
|
-
this._throwIfClosed();
|
|
643
|
-
return _value;
|
|
644
|
-
}
|
|
645
|
-
next(value) {
|
|
646
|
-
super.next((this._value = value));
|
|
647
|
-
}
|
|
648
|
-
}
|
|
649
|
-
|
|
650
|
-
export { BehaviorSubject as B, Observable as O };
|
|
651
|
-
|
|
652
|
-
//# sourceMappingURL=p-74be971f.js.map
|