@aiconomy/aico-components 0.0.13 → 0.0.53
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/aico-components/aico-components.css +6 -0
- package/dist/aico-components/aico-components.esm.js +2 -0
- package/dist/aico-components/aico-components.esm.js.map +1 -0
- package/dist/aico-components/assets/slick/ajax-loader.gif +0 -0
- package/dist/aico-components/assets/slick/slick.eot +0 -0
- package/dist/aico-components/assets/slick/slick.svg +14 -0
- package/dist/aico-components/assets/slick/slick.ttf +0 -0
- package/dist/aico-components/assets/slick/slick.woff +0 -0
- package/dist/aico-components/index.esm.js +2 -0
- package/dist/aico-components/index.esm.js.map +1 -0
- package/dist/aico-components/p-1a6625c0.entry.js +2 -0
- package/dist/aico-components/p-1a6625c0.entry.js.map +1 -0
- package/dist/aico-components/p-2aae1a0e.js +3 -0
- package/dist/aico-components/p-2aae1a0e.js.map +1 -0
- package/dist/aico-components/p-31666f10.js +2 -0
- package/dist/aico-components/p-31666f10.js.map +1 -0
- package/dist/aico-components/p-42b98baf.entry.js +2 -0
- package/dist/aico-components/p-42b98baf.entry.js.map +1 -0
- package/dist/aico-components/p-54708dd0.entry.js +2 -0
- package/dist/aico-components/p-54708dd0.entry.js.map +1 -0
- package/dist/aico-components/p-776352ba.entry.js +2 -0
- package/dist/aico-components/p-776352ba.entry.js.map +1 -0
- package/dist/aico-components/p-7c05cd02.entry.js +2 -0
- package/dist/aico-components/p-7c05cd02.entry.js.map +1 -0
- package/dist/aico-components/p-83655dd4.entry.js +2 -0
- package/dist/aico-components/p-83655dd4.entry.js.map +1 -0
- package/dist/aico-components/p-86c7fdc7.js +13 -0
- package/dist/aico-components/p-86c7fdc7.js.map +1 -0
- package/dist/aico-components/p-a58972e9.entry.js +7 -0
- package/dist/aico-components/p-a58972e9.entry.js.map +1 -0
- package/dist/aico-components/p-b0325a83.entry.js +2 -0
- package/dist/aico-components/p-b0325a83.entry.js.map +1 -0
- package/dist/aico-components/p-b78d7799.entry.js +2 -0
- package/dist/aico-components/p-b78d7799.entry.js.map +1 -0
- package/dist/aico-components/p-c99617a8.entry.js +2 -0
- package/dist/aico-components/p-c99617a8.entry.js.map +1 -0
- package/dist/cjs/aico-album-content_19.cjs.entry.js +6906 -0
- package/dist/cjs/aico-album-content_19.cjs.entry.js.map +1 -0
- package/dist/cjs/aico-article-detail.cjs.entry.js +124 -0
- package/dist/cjs/aico-article-detail.cjs.entry.js.map +1 -0
- package/dist/cjs/aico-asking-list-content.cjs.entry.js +21 -0
- package/dist/cjs/aico-asking-list-content.cjs.entry.js.map +1 -0
- package/dist/cjs/aico-collection-content.cjs.entry.js +21 -0
- package/dist/cjs/aico-collection-content.cjs.entry.js.map +1 -0
- package/dist/cjs/aico-components.cjs.js +25 -0
- package/dist/cjs/aico-components.cjs.js.map +1 -0
- package/dist/cjs/aico-fetch-article-detail.cjs.entry.js +36 -0
- package/dist/cjs/aico-fetch-article-detail.cjs.entry.js.map +1 -0
- package/dist/cjs/aico-news-list-item.cjs.entry.js +24 -0
- package/dist/cjs/aico-news-list-item.cjs.entry.js.map +1 -0
- package/dist/cjs/aico-news-list.cjs.entry.js +92 -0
- package/dist/cjs/aico-news-list.cjs.entry.js.map +1 -0
- package/dist/cjs/aico-no-content_2.cjs.entry.js +49 -0
- package/dist/cjs/aico-no-content_2.cjs.entry.js.map +1 -0
- package/dist/cjs/aico-special-news-carousel.cjs.entry.js +60 -0
- package/dist/cjs/aico-special-news-carousel.cjs.entry.js.map +1 -0
- package/dist/cjs/bootstrap-slick-test.cjs.entry.js +38 -0
- package/dist/cjs/bootstrap-slick-test.cjs.entry.js.map +1 -0
- package/dist/cjs/index-75c0e002.js +2280 -0
- package/dist/cjs/index-75c0e002.js.map +1 -0
- package/dist/cjs/index.cjs.js +4 -0
- package/dist/cjs/index.cjs.js.map +1 -0
- package/dist/cjs/loader.cjs.js +15 -0
- package/dist/cjs/loader.cjs.js.map +1 -0
- package/dist/cjs/slick-d0dfbd94.js +13662 -0
- package/dist/cjs/slick-d0dfbd94.js.map +1 -0
- package/dist/cjs/utils-406a9df3.js +92 -0
- package/dist/cjs/utils-406a9df3.js.map +1 -0
- package/dist/collection/assets/slick/ajax-loader.gif +0 -0
- package/dist/collection/assets/slick/slick.eot +0 -0
- package/dist/collection/assets/slick/slick.svg +14 -0
- package/dist/collection/assets/slick/slick.ttf +0 -0
- package/dist/collection/assets/slick/slick.woff +0 -0
- package/dist/collection/collection-manifest.json +40 -0
- package/dist/collection/components/aico-article-detail/aico-article-detail.css +0 -0
- package/dist/collection/components/aico-article-detail/aico-article-detail.js +117 -0
- package/dist/collection/components/aico-article-detail/aico-article-detail.js.map +1 -0
- package/dist/collection/components/aico-article-detail/test/aico-article-detail.e2e.js +6 -0
- package/dist/collection/components/aico-article-detail/test/aico-article-detail.e2e.js.map +1 -0
- package/dist/collection/components/aico-article-detail/test/aico-article-detail.spec.js +6 -0
- package/dist/collection/components/aico-article-detail/test/aico-article-detail.spec.js.map +1 -0
- package/dist/collection/components/aico-fetch-article-detail/aico-fetch-article-detail.css +0 -0
- package/dist/collection/components/aico-fetch-article-detail/aico-fetch-article-detail.js +96 -0
- package/dist/collection/components/aico-fetch-article-detail/aico-fetch-article-detail.js.map +1 -0
- package/dist/collection/components/aico-fetch-article-detail/aico-fetch-article-detail.stories.js +19 -0
- package/dist/collection/components/aico-fetch-article-detail/aico-fetch-article-detail.stories.js.map +1 -0
- package/dist/collection/components/aico-fetch-article-detail/test/aico-fetch-article-detail.e2e.js +6 -0
- package/dist/collection/components/aico-fetch-article-detail/test/aico-fetch-article-detail.e2e.js.map +1 -0
- package/dist/collection/components/aico-fetch-article-detail/test/aico-fetch-article-detail.spec.js +6 -0
- package/dist/collection/components/aico-fetch-article-detail/test/aico-fetch-article-detail.spec.js.map +1 -0
- package/dist/collection/components/aico-news-list/aico-news-list.css +113 -0
- package/dist/collection/components/aico-news-list/aico-news-list.js +195 -0
- package/dist/collection/components/aico-news-list/aico-news-list.js.map +1 -0
- package/dist/collection/components/aico-news-list/aico-news-list.stories.js +21 -0
- package/dist/collection/components/aico-news-list/aico-news-list.stories.js.map +1 -0
- package/dist/collection/components/aico-news-list/test/aico-news-list.e2e.js +6 -0
- package/dist/collection/components/aico-news-list/test/aico-news-list.e2e.js.map +1 -0
- package/dist/collection/components/aico-news-list/test/aico-news-list.spec.js +6 -0
- package/dist/collection/components/aico-news-list/test/aico-news-list.spec.js.map +1 -0
- package/dist/collection/components/aico-news-list-item/aico-news-list-item.css +0 -0
- package/dist/collection/components/aico-news-list-item/aico-news-list-item.js +72 -0
- package/dist/collection/components/aico-news-list-item/aico-news-list-item.js.map +1 -0
- package/dist/collection/components/aico-news-list-item/aico-news-list-item.stories.js +61 -0
- package/dist/collection/components/aico-news-list-item/aico-news-list-item.stories.js.map +1 -0
- package/dist/collection/components/aico-news-list-item/test/aico-news-list-item.e2e.js +6 -0
- package/dist/collection/components/aico-news-list-item/test/aico-news-list-item.e2e.js.map +1 -0
- package/dist/collection/components/aico-news-list-item/test/aico-news-list-item.spec.js +6 -0
- package/dist/collection/components/aico-news-list-item/test/aico-news-list-item.spec.js.map +1 -0
- package/dist/collection/components/aico-special-news-carousel/aico-special-news-carousel.css +3 -0
- package/dist/collection/components/aico-special-news-carousel/aico-special-news-carousel.js +145 -0
- package/dist/collection/components/aico-special-news-carousel/aico-special-news-carousel.js.map +1 -0
- package/dist/collection/components/aico-special-news-carousel/aico-special-news-carousel.stories.js +30 -0
- package/dist/collection/components/aico-special-news-carousel/aico-special-news-carousel.stories.js.map +1 -0
- package/dist/collection/components/aico-special-news-carousel/test/aico-special-news-carousel.e2e.js +6 -0
- package/dist/collection/components/aico-special-news-carousel/test/aico-special-news-carousel.e2e.js.map +1 -0
- package/dist/collection/components/aico-special-news-carousel/test/aico-special-news-carousel.spec.js +6 -0
- package/dist/collection/components/aico-special-news-carousel/test/aico-special-news-carousel.spec.js.map +1 -0
- package/dist/collection/components/bootstrap-slick-test/bootstrap-slick-test.css +6 -0
- package/dist/collection/components/bootstrap-slick-test/bootstrap-slick-test.js +37 -0
- package/dist/collection/components/bootstrap-slick-test/bootstrap-slick-test.js.map +1 -0
- package/dist/collection/components/bootstrap-slick-test/bootstrap-slick-test.stories.js +6 -0
- package/dist/collection/components/bootstrap-slick-test/bootstrap-slick-test.stories.js.map +1 -0
- package/dist/collection/components/content/aico-album-content/aico-album-content.css +0 -0
- package/dist/collection/components/content/aico-album-content/aico-album-content.js +104 -0
- package/dist/collection/components/content/aico-album-content/aico-album-content.js.map +1 -0
- package/dist/collection/components/content/aico-album-content/aico-album-content.stories.js +70 -0
- package/dist/collection/components/content/aico-album-content/aico-album-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-asking-content/aico-asking-content.css +63 -0
- package/dist/collection/components/content/aico-asking-content/aico-asking-content.js +49 -0
- package/dist/collection/components/content/aico-asking-content/aico-asking-content.js.map +1 -0
- package/dist/collection/components/content/aico-asking-content/aico-asking-content.stories.js +37 -0
- package/dist/collection/components/content/aico-asking-content/aico-asking-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-asking-list-content/aico-asking-list-content.css +85 -0
- package/dist/collection/components/content/aico-asking-list-content/aico-asking-list-content.js +19 -0
- package/dist/collection/components/content/aico-asking-list-content/aico-asking-list-content.js.map +1 -0
- package/dist/collection/components/content/aico-block-quote-content/aico-block-quote-content.css +0 -0
- package/dist/collection/components/content/aico-block-quote-content/aico-block-quote-content.js +49 -0
- package/dist/collection/components/content/aico-block-quote-content/aico-block-quote-content.js.map +1 -0
- package/dist/collection/components/content/aico-block-quote-content/aico-block-quote-content.stories.js +26 -0
- package/dist/collection/components/content/aico-block-quote-content/aico-block-quote-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-bullet-content/aico-bullet-content.css +0 -0
- package/dist/collection/components/content/aico-bullet-content/aico-bullet-content.js +79 -0
- package/dist/collection/components/content/aico-bullet-content/aico-bullet-content.js.map +1 -0
- package/dist/collection/components/content/aico-bullet-content/aico-bullet-content.stories.js +71 -0
- package/dist/collection/components/content/aico-bullet-content/aico-bullet-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-carousel-content/aico-carousel-content.css +1 -0
- package/dist/collection/components/content/aico-carousel-content/aico-carousel-content.js +95 -0
- package/dist/collection/components/content/aico-carousel-content/aico-carousel-content.js.map +1 -0
- package/dist/collection/components/content/aico-carousel-content/aico-carousel-content.stories.js +73 -0
- package/dist/collection/components/content/aico-carousel-content/aico-carousel-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-collection-content/aico-collection-content.css +3 -0
- package/dist/collection/components/content/aico-collection-content/aico-collection-content.js +19 -0
- package/dist/collection/components/content/aico-collection-content/aico-collection-content.js.map +1 -0
- package/dist/collection/components/content/aico-content-card-content/aico-content-card-content.css +0 -0
- package/dist/collection/components/content/aico-content-card-content/aico-content-card-content.js +62 -0
- package/dist/collection/components/content/aico-content-card-content/aico-content-card-content.js.map +1 -0
- package/dist/collection/components/content/aico-content-card-content/aico-content-card-content.stories.js +26 -0
- package/dist/collection/components/content/aico-content-card-content/aico-content-card-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-divider-content/aico-divider-content.css +0 -0
- package/dist/collection/components/content/aico-divider-content/aico-divider-content.js +49 -0
- package/dist/collection/components/content/aico-divider-content/aico-divider-content.js.map +1 -0
- package/dist/collection/components/content/aico-divider-content/aico-divider-content.stories.js +23 -0
- package/dist/collection/components/content/aico-divider-content/aico-divider-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-document-content/aico-document-content.css +8 -0
- package/dist/collection/components/content/aico-document-content/aico-document-content.js +73 -0
- package/dist/collection/components/content/aico-document-content/aico-document-content.js.map +1 -0
- package/dist/collection/components/content/aico-document-content/aico-document-content.stories.js +30 -0
- package/dist/collection/components/content/aico-document-content/aico-document-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-faq-content/aico-faq-content.css +0 -0
- package/dist/collection/components/content/aico-faq-content/aico-faq-content.js +54 -0
- package/dist/collection/components/content/aico-faq-content/aico-faq-content.js.map +1 -0
- package/dist/collection/components/content/aico-faq-content/aico-faq-content.stories.js +60 -0
- package/dist/collection/components/content/aico-faq-content/aico-faq-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-heading-content/aico-heading-content.css +36 -0
- package/dist/collection/components/content/aico-heading-content/aico-heading-content.js +81 -0
- package/dist/collection/components/content/aico-heading-content/aico-heading-content.js.map +1 -0
- package/dist/collection/components/content/aico-heading-content/aico-heading-content.stories.js +31 -0
- package/dist/collection/components/content/aico-heading-content/aico-heading-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-html-content/aico-html-content.css +3 -0
- package/dist/collection/components/content/aico-html-content/aico-html-content.js +52 -0
- package/dist/collection/components/content/aico-html-content/aico-html-content.js.map +1 -0
- package/dist/collection/components/content/aico-link-content/aico-link-content.css +37 -0
- package/dist/collection/components/content/aico-link-content/aico-link-content.js +68 -0
- package/dist/collection/components/content/aico-link-content/aico-link-content.js.map +1 -0
- package/dist/collection/components/content/aico-link-content/aico-link-content.stories.js +59 -0
- package/dist/collection/components/content/aico-link-content/aico-link-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-news-content/aico-news-content.css +11 -0
- package/dist/collection/components/content/aico-news-content/aico-news-content.js +79 -0
- package/dist/collection/components/content/aico-news-content/aico-news-content.js.map +1 -0
- package/dist/collection/components/content/aico-news-content/aico-news-content.stories.js +43 -0
- package/dist/collection/components/content/aico-news-content/aico-news-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-no-content/aico-no-content.css +3 -0
- package/dist/collection/components/content/aico-no-content/aico-no-content.js +19 -0
- package/dist/collection/components/content/aico-no-content/aico-no-content.js.map +1 -0
- package/dist/collection/components/content/aico-page-content/aico-page-content.css +3 -0
- package/dist/collection/components/content/aico-page-content/aico-page-content.js +79 -0
- package/dist/collection/components/content/aico-page-content/aico-page-content.js.map +1 -0
- package/dist/collection/components/content/aico-page-content/aico-page-content.stories.js +37 -0
- package/dist/collection/components/content/aico-page-content/aico-page-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-table-content/aico-table-content.css +21 -0
- package/dist/collection/components/content/aico-table-content/aico-table-content.js +73 -0
- package/dist/collection/components/content/aico-table-content/aico-table-content.js.map +1 -0
- package/dist/collection/components/content/aico-table-content/aico-table-content.stories.js +130 -0
- package/dist/collection/components/content/aico-table-content/aico-table-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-testimonial-content/aico-testimonial-content.css +93 -0
- package/dist/collection/components/content/aico-testimonial-content/aico-testimonial-content.js +51 -0
- package/dist/collection/components/content/aico-testimonial-content/aico-testimonial-content.js.map +1 -0
- package/dist/collection/components/content/aico-testimonial-content/aico-testimonial-content.stories.js +23 -0
- package/dist/collection/components/content/aico-testimonial-content/aico-testimonial-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-text-content/aico-text-content.css +0 -0
- package/dist/collection/components/content/aico-text-content/aico-text-content.js +127 -0
- package/dist/collection/components/content/aico-text-content/aico-text-content.js.map +1 -0
- package/dist/collection/components/content/aico-text-content/aico-text-content.stories.js +173 -0
- package/dist/collection/components/content/aico-text-content/aico-text-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-title-content/aico-title-content.css +3 -0
- package/dist/collection/components/content/aico-title-content/aico-title-content.js +61 -0
- package/dist/collection/components/content/aico-title-content/aico-title-content.js.map +1 -0
- package/dist/collection/components/content/aico-title-content/aico-title-content.stories.js +28 -0
- package/dist/collection/components/content/aico-title-content/aico-title-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-upload-content/aico-upload-content.css +3 -0
- package/dist/collection/components/content/aico-upload-content/aico-upload-content.js +66 -0
- package/dist/collection/components/content/aico-upload-content/aico-upload-content.js.map +1 -0
- package/dist/collection/components/content/aico-upload-content/aico-upload-content.stories.js +39 -0
- package/dist/collection/components/content/aico-upload-content/aico-upload-content.stories.js.map +1 -0
- package/dist/collection/components/content/aico-video-content/aico-video-content.css +10 -0
- package/dist/collection/components/content/aico-video-content/aico-video-content.js +62 -0
- package/dist/collection/components/content/aico-video-content/aico-video-content.js.map +1 -0
- package/dist/collection/components/content/aico-video-content/aico-video-content.stories.js +43 -0
- package/dist/collection/components/content/aico-video-content/aico-video-content.stories.js.map +1 -0
- package/dist/collection/components/content/content-styles.css +113 -0
- package/dist/collection/index.js +2 -0
- package/dist/collection/index.js.map +1 -0
- package/dist/collection/model/AicoApiRequestInfo.js +13 -0
- package/dist/collection/model/AicoApiRequestInfo.js.map +1 -0
- package/dist/collection/model/Article.js +2 -0
- package/dist/collection/model/Article.js.map +1 -0
- package/dist/collection/model/Entity.js +7 -0
- package/dist/collection/model/Entity.js.map +1 -0
- package/dist/collection/model/NewsCategory.js +2 -0
- package/dist/collection/model/NewsCategory.js.map +1 -0
- package/dist/collection/model/NewsResponse.js +2 -0
- package/dist/collection/model/NewsResponse.js.map +1 -0
- package/dist/collection/model/article/ContentType.js +33 -0
- package/dist/collection/model/article/ContentType.js.map +1 -0
- package/dist/collection/model/article/Translation.js +8 -0
- package/dist/collection/model/article/Translation.js.map +1 -0
- package/dist/collection/model/article/content/AlbumContent.js +2 -0
- package/dist/collection/model/article/content/AlbumContent.js.map +1 -0
- package/dist/collection/model/article/content/AskingContent.js +21 -0
- package/dist/collection/model/article/content/AskingContent.js.map +1 -0
- package/dist/collection/model/article/content/AskingListContent.js +7 -0
- package/dist/collection/model/article/content/AskingListContent.js.map +1 -0
- package/dist/collection/model/article/content/BlockQuoteContent.js +2 -0
- package/dist/collection/model/article/content/BlockQuoteContent.js.map +1 -0
- package/dist/collection/model/article/content/BulletContent.js +2 -0
- package/dist/collection/model/article/content/BulletContent.js.map +1 -0
- package/dist/collection/model/article/content/CardContent.js +2 -0
- package/dist/collection/model/article/content/CardContent.js.map +1 -0
- package/dist/collection/model/article/content/CarouselContent.js +2 -0
- package/dist/collection/model/article/content/CarouselContent.js.map +1 -0
- package/dist/collection/model/article/content/CollectionContent.js +52 -0
- package/dist/collection/model/article/content/CollectionContent.js.map +1 -0
- package/dist/collection/model/article/content/DividerContent.js +2 -0
- package/dist/collection/model/article/content/DividerContent.js.map +1 -0
- package/dist/collection/model/article/content/DocumentContent.js +2 -0
- package/dist/collection/model/article/content/DocumentContent.js.map +1 -0
- package/dist/collection/model/article/content/FaqContent.js +12 -0
- package/dist/collection/model/article/content/FaqContent.js.map +1 -0
- package/dist/collection/model/article/content/HeadingContent.js +2 -0
- package/dist/collection/model/article/content/HeadingContent.js.map +1 -0
- package/dist/collection/model/article/content/HtmlContent.js +2 -0
- package/dist/collection/model/article/content/HtmlContent.js.map +1 -0
- package/dist/collection/model/article/content/LinkContent.js +2 -0
- package/dist/collection/model/article/content/LinkContent.js.map +1 -0
- package/dist/collection/model/article/content/NewsContent.js +19 -0
- package/dist/collection/model/article/content/NewsContent.js.map +1 -0
- package/dist/collection/model/article/content/PageContent.js +37 -0
- package/dist/collection/model/article/content/PageContent.js.map +1 -0
- package/dist/collection/model/article/content/TableContet.js +2 -0
- package/dist/collection/model/article/content/TableContet.js.map +1 -0
- package/dist/collection/model/article/content/TestimonialContent.js +2 -0
- package/dist/collection/model/article/content/TestimonialContent.js.map +1 -0
- package/dist/collection/model/article/content/TextContent.js +2 -0
- package/dist/collection/model/article/content/TextContent.js.map +1 -0
- package/dist/collection/model/article/content/TitleContent.js +2 -0
- package/dist/collection/model/article/content/TitleContent.js.map +1 -0
- package/dist/collection/model/article/content/UploadContent.js +13 -0
- package/dist/collection/model/article/content/UploadContent.js.map +1 -0
- package/dist/collection/model/article/content/VideoContent.js +2 -0
- package/dist/collection/model/article/content/VideoContent.js.map +1 -0
- package/dist/collection/model/article/content/news/NewsAlbum.js +20 -0
- package/dist/collection/model/article/content/news/NewsAlbum.js.map +1 -0
- package/dist/collection/model/article/content/news/NewsArticle.js +43 -0
- package/dist/collection/model/article/content/news/NewsArticle.js.map +1 -0
- package/dist/collection/model/article/content/news/NewsCategory.js +17 -0
- package/dist/collection/model/article/content/news/NewsCategory.js.map +1 -0
- package/dist/collection/model/article/content/news/NewsTag.js +10 -0
- package/dist/collection/model/article/content/news/NewsTag.js.map +1 -0
- package/dist/collection/utils/ConditionalRender.js +5 -0
- package/dist/collection/utils/ConditionalRender.js.map +1 -0
- package/dist/collection/utils/ConditionalWrap.js +5 -0
- package/dist/collection/utils/ConditionalWrap.js.map +1 -0
- package/dist/collection/utils/utils.js +77 -0
- package/dist/collection/utils/utils.js.map +1 -0
- package/dist/collection/utils/utils.spec.js +6 -0
- package/dist/collection/utils/utils.spec.js.map +1 -0
- package/dist/components/ConditionalRender.js +7 -0
- package/dist/components/ConditionalRender.js.map +1 -0
- package/dist/components/aico-album-content.d.ts +11 -0
- package/dist/components/aico-album-content.js +8 -0
- package/dist/components/aico-album-content.js.map +1 -0
- package/dist/components/aico-album-content2.js +90 -0
- package/dist/components/aico-album-content2.js.map +1 -0
- package/dist/components/aico-article-detail.d.ts +11 -0
- package/dist/components/aico-article-detail.js +8 -0
- package/dist/components/aico-article-detail.js.map +1 -0
- package/dist/components/aico-article-detail2.js +262 -0
- package/dist/components/aico-article-detail2.js.map +1 -0
- package/dist/components/aico-asking-content.d.ts +11 -0
- package/dist/components/aico-asking-content.js +8 -0
- package/dist/components/aico-asking-content.js.map +1 -0
- package/dist/components/aico-asking-content2.js +36 -0
- package/dist/components/aico-asking-content2.js.map +1 -0
- package/dist/components/aico-asking-list-content.d.ts +11 -0
- package/dist/components/aico-asking-list-content.js +34 -0
- package/dist/components/aico-asking-list-content.js.map +1 -0
- package/dist/components/aico-block-quote-content.d.ts +11 -0
- package/dist/components/aico-block-quote-content.js +8 -0
- package/dist/components/aico-block-quote-content.js.map +1 -0
- package/dist/components/aico-block-quote-content2.js +36 -0
- package/dist/components/aico-block-quote-content2.js.map +1 -0
- package/dist/components/aico-bullet-content.d.ts +11 -0
- package/dist/components/aico-bullet-content.js +8 -0
- package/dist/components/aico-bullet-content.js.map +1 -0
- package/dist/components/aico-bullet-content2.js +78 -0
- package/dist/components/aico-bullet-content2.js.map +1 -0
- package/dist/components/aico-carousel-content.d.ts +11 -0
- package/dist/components/aico-carousel-content.js +8 -0
- package/dist/components/aico-carousel-content.js.map +1 -0
- package/dist/components/aico-carousel-content2.js +76 -0
- package/dist/components/aico-carousel-content2.js.map +1 -0
- package/dist/components/aico-collection-content.d.ts +11 -0
- package/dist/components/aico-collection-content.js +34 -0
- package/dist/components/aico-collection-content.js.map +1 -0
- package/dist/components/aico-content-card-content.d.ts +11 -0
- package/dist/components/aico-content-card-content.js +8 -0
- package/dist/components/aico-content-card-content.js.map +1 -0
- package/dist/components/aico-content-card-content2.js +61 -0
- package/dist/components/aico-content-card-content2.js.map +1 -0
- package/dist/components/aico-divider-content.d.ts +11 -0
- package/dist/components/aico-divider-content.js +8 -0
- package/dist/components/aico-divider-content.js.map +1 -0
- package/dist/components/aico-divider-content2.js +36 -0
- package/dist/components/aico-divider-content2.js.map +1 -0
- package/dist/components/aico-document-content.d.ts +11 -0
- package/dist/components/aico-document-content.js +8 -0
- package/dist/components/aico-document-content.js.map +1 -0
- package/dist/components/aico-document-content2.js +60 -0
- package/dist/components/aico-document-content2.js.map +1 -0
- package/dist/components/aico-faq-content.d.ts +11 -0
- package/dist/components/aico-faq-content.js +8 -0
- package/dist/components/aico-faq-content.js.map +1 -0
- package/dist/components/aico-faq-content2.js +41 -0
- package/dist/components/aico-faq-content2.js.map +1 -0
- package/dist/components/aico-fetch-article-detail.d.ts +11 -0
- package/dist/components/aico-fetch-article-detail.js +186 -0
- package/dist/components/aico-fetch-article-detail.js.map +1 -0
- package/dist/components/aico-heading-content.d.ts +11 -0
- package/dist/components/aico-heading-content.js +8 -0
- package/dist/components/aico-heading-content.js.map +1 -0
- package/dist/components/aico-heading-content2.js +80 -0
- package/dist/components/aico-heading-content2.js.map +1 -0
- package/dist/components/aico-html-content.d.ts +11 -0
- package/dist/components/aico-html-content.js +8 -0
- package/dist/components/aico-html-content.js.map +1 -0
- package/dist/components/aico-html-content2.js +45 -0
- package/dist/components/aico-html-content2.js.map +1 -0
- package/dist/components/aico-link-content.d.ts +11 -0
- package/dist/components/aico-link-content.js +8 -0
- package/dist/components/aico-link-content.js.map +1 -0
- package/dist/components/aico-link-content2.js +55 -0
- package/dist/components/aico-link-content2.js.map +1 -0
- package/dist/components/aico-news-content.d.ts +11 -0
- package/dist/components/aico-news-content.js +8 -0
- package/dist/components/aico-news-content.js.map +1 -0
- package/dist/components/aico-news-content2.js +43 -0
- package/dist/components/aico-news-content2.js.map +1 -0
- package/dist/components/aico-news-list-item.d.ts +11 -0
- package/dist/components/aico-news-list-item.js +8 -0
- package/dist/components/aico-news-list-item.js.map +1 -0
- package/dist/components/aico-news-list-item2.js +36 -0
- package/dist/components/aico-news-list-item2.js.map +1 -0
- package/dist/components/aico-news-list.d.ts +11 -0
- package/dist/components/aico-news-list.js +118 -0
- package/dist/components/aico-news-list.js.map +1 -0
- package/dist/components/aico-no-content.d.ts +11 -0
- package/dist/components/aico-no-content.js +8 -0
- package/dist/components/aico-no-content.js.map +1 -0
- package/dist/components/aico-no-content2.js +31 -0
- package/dist/components/aico-no-content2.js.map +1 -0
- package/dist/components/aico-page-content.d.ts +11 -0
- package/dist/components/aico-page-content.js +8 -0
- package/dist/components/aico-page-content.js.map +1 -0
- package/dist/components/aico-page-content2.js +43 -0
- package/dist/components/aico-page-content2.js.map +1 -0
- package/dist/components/aico-special-news-carousel.d.ts +11 -0
- package/dist/components/aico-special-news-carousel.js +78 -0
- package/dist/components/aico-special-news-carousel.js.map +1 -0
- package/dist/components/aico-table-content.d.ts +11 -0
- package/dist/components/aico-table-content.js +8 -0
- package/dist/components/aico-table-content.js.map +1 -0
- package/dist/components/aico-table-content2.js +72 -0
- package/dist/components/aico-table-content2.js.map +1 -0
- package/dist/components/aico-testimonial-content.d.ts +11 -0
- package/dist/components/aico-testimonial-content.js +8 -0
- package/dist/components/aico-testimonial-content.js.map +1 -0
- package/dist/components/aico-testimonial-content2.js +38 -0
- package/dist/components/aico-testimonial-content2.js.map +1 -0
- package/dist/components/aico-text-content.d.ts +11 -0
- package/dist/components/aico-text-content.js +8 -0
- package/dist/components/aico-text-content.js.map +1 -0
- package/dist/components/aico-text-content2.js +127 -0
- package/dist/components/aico-text-content2.js.map +1 -0
- package/dist/components/aico-title-content.d.ts +11 -0
- package/dist/components/aico-title-content.js +8 -0
- package/dist/components/aico-title-content.js.map +1 -0
- package/dist/components/aico-title-content2.js +54 -0
- package/dist/components/aico-title-content2.js.map +1 -0
- package/dist/components/aico-upload-content.d.ts +11 -0
- package/dist/components/aico-upload-content.js +8 -0
- package/dist/components/aico-upload-content.js.map +1 -0
- package/dist/components/aico-upload-content2.js +65 -0
- package/dist/components/aico-upload-content2.js.map +1 -0
- package/dist/components/aico-video-content.d.ts +11 -0
- package/dist/components/aico-video-content.js +8 -0
- package/dist/components/aico-video-content.js.map +1 -0
- package/dist/components/aico-video-content2.js +61 -0
- package/dist/components/aico-video-content2.js.map +1 -0
- package/dist/components/assets/slick/ajax-loader.gif +0 -0
- package/dist/components/assets/slick/slick.eot +0 -0
- package/dist/components/assets/slick/slick.svg +14 -0
- package/dist/components/assets/slick/slick.ttf +0 -0
- package/dist/components/assets/slick/slick.woff +0 -0
- package/dist/components/bootstrap-slick-test.d.ts +11 -0
- package/dist/components/bootstrap-slick-test.js +51 -0
- package/dist/components/bootstrap-slick-test.js.map +1 -0
- package/dist/components/bootstrap.esm.js +6265 -0
- package/dist/components/bootstrap.esm.js.map +1 -0
- package/dist/components/index.d.ts +33 -0
- package/dist/components/index.js +3 -0
- package/dist/components/index.js.map +1 -0
- package/dist/components/slick.js +13660 -0
- package/dist/components/slick.js.map +1 -0
- package/dist/components/utils.js +84 -0
- package/dist/components/utils.js.map +1 -0
- package/dist/esm/aico-album-content_19.entry.js +6884 -0
- package/dist/esm/aico-album-content_19.entry.js.map +1 -0
- package/dist/esm/aico-article-detail.entry.js +120 -0
- package/dist/esm/aico-article-detail.entry.js.map +1 -0
- package/dist/esm/aico-asking-list-content.entry.js +17 -0
- package/dist/esm/aico-asking-list-content.entry.js.map +1 -0
- package/dist/esm/aico-collection-content.entry.js +17 -0
- package/dist/esm/aico-collection-content.entry.js.map +1 -0
- package/dist/esm/aico-components.js +20 -0
- package/dist/esm/aico-components.js.map +1 -0
- package/dist/esm/aico-fetch-article-detail.entry.js +32 -0
- package/dist/esm/aico-fetch-article-detail.entry.js.map +1 -0
- package/dist/esm/aico-news-list-item.entry.js +20 -0
- package/dist/esm/aico-news-list-item.entry.js.map +1 -0
- package/dist/esm/aico-news-list.entry.js +88 -0
- package/dist/esm/aico-news-list.entry.js.map +1 -0
- package/dist/esm/aico-no-content_2.entry.js +44 -0
- package/dist/esm/aico-no-content_2.entry.js.map +1 -0
- package/dist/esm/aico-special-news-carousel.entry.js +56 -0
- package/dist/esm/aico-special-news-carousel.entry.js.map +1 -0
- package/dist/esm/bootstrap-slick-test.entry.js +34 -0
- package/dist/esm/bootstrap-slick-test.entry.js.map +1 -0
- package/dist/esm/index-f9f11572.js +2250 -0
- package/dist/esm/index-f9f11572.js.map +1 -0
- package/dist/esm/index.js +3 -0
- package/dist/esm/index.js.map +1 -0
- package/dist/esm/loader.js +11 -0
- package/dist/esm/loader.js.map +1 -0
- package/dist/esm/polyfills/core-js.js +11 -0
- package/dist/esm/polyfills/dom.js +79 -0
- package/dist/esm/polyfills/es5-html-element.js +1 -0
- package/dist/esm/polyfills/index.js +34 -0
- package/dist/esm/polyfills/system.js +6 -0
- package/dist/esm/slick-d11cf173.js +13660 -0
- package/dist/esm/slick-d11cf173.js.map +1 -0
- package/dist/esm/utils-2b7ec879.js +84 -0
- package/dist/esm/utils-2b7ec879.js.map +1 -0
- package/dist/index.cjs.js +1 -0
- package/dist/index.js +1 -0
- package/dist/types/components/aico-article-detail/aico-article-detail.d.ts +10 -0
- package/dist/types/components/aico-fetch-article-detail/aico-fetch-article-detail.d.ts +13 -0
- package/dist/types/components/aico-fetch-article-detail/aico-fetch-article-detail.stories.d.ts +7 -0
- package/dist/types/components/aico-news-list/aico-news-list.d.ts +21 -0
- package/dist/types/components/aico-news-list/aico-news-list.stories.d.ts +6 -0
- package/dist/types/components/aico-news-list-item/aico-news-list-item.d.ts +7 -0
- package/dist/types/components/aico-news-list-item/aico-news-list-item.stories.d.ts +6 -0
- package/dist/types/components/aico-special-news-carousel/aico-special-news-carousel.d.ts +19 -0
- package/dist/types/components/aico-special-news-carousel/aico-special-news-carousel.stories.d.ts +7 -0
- package/dist/types/components/bootstrap-slick-test/bootstrap-slick-test.d.ts +5 -0
- package/dist/types/components/bootstrap-slick-test/bootstrap-slick-test.stories.d.ts +5 -0
- package/dist/types/components/content/aico-album-content/aico-album-content.d.ts +7 -0
- package/dist/types/components/content/aico-album-content/aico-album-content.stories.d.ts +5 -0
- package/dist/types/components/content/aico-asking-content/aico-asking-content.d.ts +5 -0
- package/dist/types/components/content/aico-asking-content/aico-asking-content.stories.d.ts +5 -0
- package/dist/types/components/content/aico-asking-list-content/aico-asking-list-content.d.ts +3 -0
- package/dist/types/components/content/aico-block-quote-content/aico-block-quote-content.d.ts +5 -0
- package/dist/types/components/content/aico-block-quote-content/aico-block-quote-content.stories.d.ts +6 -0
- package/dist/types/components/content/aico-bullet-content/aico-bullet-content.d.ts +6 -0
- package/dist/types/components/content/aico-bullet-content/aico-bullet-content.stories.d.ts +6 -0
- package/dist/types/components/content/aico-carousel-content/aico-carousel-content.d.ts +9 -0
- package/dist/types/components/content/aico-carousel-content/aico-carousel-content.stories.d.ts +6 -0
- package/dist/types/components/content/aico-collection-content/aico-collection-content.d.ts +3 -0
- package/dist/types/components/content/aico-content-card-content/aico-content-card-content.d.ts +6 -0
- package/dist/types/components/content/aico-content-card-content/aico-content-card-content.stories.d.ts +6 -0
- package/dist/types/components/content/aico-divider-content/aico-divider-content.d.ts +5 -0
- package/dist/types/components/content/aico-divider-content/aico-divider-content.stories.d.ts +6 -0
- package/dist/types/components/content/aico-document-content/aico-document-content.d.ts +5 -0
- package/dist/types/components/content/aico-document-content/aico-document-content.stories.d.ts +6 -0
- package/dist/types/components/content/aico-faq-content/aico-faq-content.d.ts +6 -0
- package/dist/types/components/content/aico-faq-content/aico-faq-content.stories.d.ts +6 -0
- package/dist/types/components/content/aico-heading-content/aico-heading-content.d.ts +6 -0
- package/dist/types/components/content/aico-heading-content/aico-heading-content.stories.d.ts +6 -0
- package/dist/types/components/content/aico-html-content/aico-html-content.d.ts +5 -0
- package/dist/types/components/content/aico-link-content/aico-link-content.d.ts +5 -0
- package/dist/types/components/content/aico-link-content/aico-link-content.stories.d.ts +7 -0
- package/dist/types/components/content/aico-news-content/aico-news-content.d.ts +8 -0
- package/dist/types/components/content/aico-news-content/aico-news-content.stories.d.ts +5 -0
- package/dist/types/components/content/aico-no-content/aico-no-content.d.ts +3 -0
- package/dist/types/components/content/aico-page-content/aico-page-content.d.ts +7 -0
- package/dist/types/components/content/aico-page-content/aico-page-content.stories.d.ts +5 -0
- package/dist/types/components/content/aico-table-content/aico-table-content.d.ts +6 -0
- package/dist/types/components/content/aico-table-content/aico-table-content.stories.d.ts +6 -0
- package/dist/types/components/content/aico-testimonial-content/aico-testimonial-content.d.ts +5 -0
- package/dist/types/components/content/aico-testimonial-content/aico-testimonial-content.stories.d.ts +6 -0
- package/dist/types/components/content/aico-text-content/aico-text-content.d.ts +12 -0
- package/dist/types/components/content/aico-text-content/aico-text-content.stories.d.ts +10 -0
- package/dist/types/components/content/aico-title-content/aico-title-content.d.ts +5 -0
- package/dist/types/components/content/aico-title-content/aico-title-content.stories.d.ts +5 -0
- package/dist/types/components/content/aico-upload-content/aico-upload-content.d.ts +6 -0
- package/dist/types/components/content/aico-upload-content/aico-upload-content.stories.d.ts +5 -0
- package/dist/types/components/content/aico-video-content/aico-video-content.d.ts +6 -0
- package/dist/types/components/content/aico-video-content/aico-video-content.stories.d.ts +7 -0
- package/dist/types/components.d.ts +591 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/model/AicoApiRequestInfo.d.ts +6 -0
- package/dist/types/model/Article.d.ts +103 -0
- package/dist/types/model/Entity.d.ts +15 -0
- package/dist/types/model/NewsCategory.d.ts +14 -0
- package/dist/types/model/NewsResponse.d.ts +25 -0
- package/dist/types/model/article/ContentType.d.ts +31 -0
- package/dist/types/model/article/Translation.d.ts +24 -0
- package/dist/types/model/article/content/AlbumContent.d.ts +26 -0
- package/dist/types/model/article/content/AskingContent.d.ts +152 -0
- package/dist/types/model/article/content/AskingListContent.d.ts +17 -0
- package/dist/types/model/article/content/BlockQuoteContent.d.ts +11 -0
- package/dist/types/model/article/content/BulletContent.d.ts +14 -0
- package/dist/types/model/article/content/CardContent.d.ts +10 -0
- package/dist/types/model/article/content/CarouselContent.d.ts +12 -0
- package/dist/types/model/article/content/CollectionContent.d.ts +364 -0
- package/dist/types/model/article/content/DividerContent.d.ts +8 -0
- package/dist/types/model/article/content/DocumentContent.d.ts +19 -0
- package/dist/types/model/article/content/FaqContent.d.ts +106 -0
- package/dist/types/model/article/content/HeadingContent.d.ts +16 -0
- package/dist/types/model/article/content/HtmlContent.d.ts +5 -0
- package/dist/types/model/article/content/LinkContent.d.ts +23 -0
- package/dist/types/model/article/content/NewsContent.d.ts +836 -0
- package/dist/types/model/article/content/PageContent.d.ts +313 -0
- package/dist/types/model/article/content/TableContet.d.ts +30 -0
- package/dist/types/model/article/content/TestimonialContent.d.ts +9 -0
- package/dist/types/model/article/content/TextContent.d.ts +39 -0
- package/dist/types/model/article/content/TitleContent.d.ts +9 -0
- package/dist/types/model/article/content/UploadContent.d.ts +77 -0
- package/dist/types/model/article/content/VideoContent.d.ts +14 -0
- package/dist/types/model/article/content/news/NewsAlbum.d.ts +150 -0
- package/dist/types/model/article/content/news/NewsArticle.d.ts +577 -0
- package/dist/types/model/article/content/news/NewsCategory.d.ts +88 -0
- package/dist/types/model/article/content/news/NewsTag.d.ts +63 -0
- package/dist/types/stencil-public-runtime.d.ts +1681 -0
- package/dist/types/utils/ConditionalRender.d.ts +6 -0
- package/dist/types/utils/ConditionalWrap.d.ts +7 -0
- package/dist/types/utils/utils.d.ts +13 -0
- package/loader/cdn.js +3 -0
- package/loader/index.cjs.js +3 -0
- package/loader/index.d.ts +21 -0
- package/loader/index.es2017.js +3 -0
- package/loader/index.js +4 -0
- package/loader/package.json +11 -0
- package/package.json +13 -4
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
const meta = {
|
|
2
|
+
component: 'aico-table-content',
|
|
3
|
+
};
|
|
4
|
+
export default meta;
|
|
5
|
+
export const Example = {
|
|
6
|
+
args: {
|
|
7
|
+
content: {
|
|
8
|
+
id: 1234,
|
|
9
|
+
createdAt: new Date(),
|
|
10
|
+
updatedAt: new Date(),
|
|
11
|
+
translations: [
|
|
12
|
+
{
|
|
13
|
+
id: 1234,
|
|
14
|
+
createdAt: new Date(),
|
|
15
|
+
updatedAt: new Date(),
|
|
16
|
+
title: 'Table title',
|
|
17
|
+
additionalText: 'Additional text',
|
|
18
|
+
},
|
|
19
|
+
],
|
|
20
|
+
tableRows: [
|
|
21
|
+
{
|
|
22
|
+
id: 1234,
|
|
23
|
+
createdAt: new Date(),
|
|
24
|
+
updatedAt: new Date(),
|
|
25
|
+
isHeading: true,
|
|
26
|
+
sort: 1,
|
|
27
|
+
rowColumns: [
|
|
28
|
+
{
|
|
29
|
+
id: 1234,
|
|
30
|
+
createdAt: new Date(),
|
|
31
|
+
updatedAt: new Date(),
|
|
32
|
+
translations: [
|
|
33
|
+
{
|
|
34
|
+
id: 1234,
|
|
35
|
+
createdAt: new Date(),
|
|
36
|
+
updatedAt: new Date(),
|
|
37
|
+
columnData: 'Heading 1',
|
|
38
|
+
},
|
|
39
|
+
],
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
id: 1234,
|
|
43
|
+
createdAt: new Date(),
|
|
44
|
+
updatedAt: new Date(),
|
|
45
|
+
translations: [
|
|
46
|
+
{
|
|
47
|
+
id: 1234,
|
|
48
|
+
createdAt: new Date(),
|
|
49
|
+
updatedAt: new Date(),
|
|
50
|
+
columnData: 'Heading 2',
|
|
51
|
+
},
|
|
52
|
+
],
|
|
53
|
+
},
|
|
54
|
+
],
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
id: 1234,
|
|
58
|
+
createdAt: new Date(),
|
|
59
|
+
updatedAt: new Date(),
|
|
60
|
+
isHeading: false,
|
|
61
|
+
sort: 3,
|
|
62
|
+
rowColumns: [
|
|
63
|
+
{
|
|
64
|
+
id: 1234,
|
|
65
|
+
createdAt: new Date(),
|
|
66
|
+
updatedAt: new Date(),
|
|
67
|
+
translations: [
|
|
68
|
+
{
|
|
69
|
+
id: 1234,
|
|
70
|
+
createdAt: new Date(),
|
|
71
|
+
updatedAt: new Date(),
|
|
72
|
+
columnData: 'Cell 1x2',
|
|
73
|
+
},
|
|
74
|
+
],
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
id: 1234,
|
|
78
|
+
createdAt: new Date(),
|
|
79
|
+
updatedAt: new Date(),
|
|
80
|
+
translations: [
|
|
81
|
+
{
|
|
82
|
+
id: 1234,
|
|
83
|
+
createdAt: new Date(),
|
|
84
|
+
updatedAt: new Date(),
|
|
85
|
+
columnData: 'Cell 2x2',
|
|
86
|
+
},
|
|
87
|
+
],
|
|
88
|
+
},
|
|
89
|
+
],
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
id: 1234,
|
|
93
|
+
createdAt: new Date(),
|
|
94
|
+
updatedAt: new Date(),
|
|
95
|
+
isHeading: false,
|
|
96
|
+
sort: 2,
|
|
97
|
+
rowColumns: [
|
|
98
|
+
{
|
|
99
|
+
id: 1234,
|
|
100
|
+
createdAt: new Date(),
|
|
101
|
+
updatedAt: new Date(),
|
|
102
|
+
translations: [
|
|
103
|
+
{
|
|
104
|
+
id: 1234,
|
|
105
|
+
createdAt: new Date(),
|
|
106
|
+
updatedAt: new Date(),
|
|
107
|
+
columnData: 'Cell 1x1',
|
|
108
|
+
},
|
|
109
|
+
],
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
id: 1234,
|
|
113
|
+
createdAt: new Date(),
|
|
114
|
+
updatedAt: new Date(),
|
|
115
|
+
translations: [
|
|
116
|
+
{
|
|
117
|
+
id: 1234,
|
|
118
|
+
createdAt: new Date(),
|
|
119
|
+
updatedAt: new Date(),
|
|
120
|
+
columnData: 'Cell 2x1',
|
|
121
|
+
},
|
|
122
|
+
],
|
|
123
|
+
},
|
|
124
|
+
],
|
|
125
|
+
},
|
|
126
|
+
],
|
|
127
|
+
},
|
|
128
|
+
},
|
|
129
|
+
};
|
|
130
|
+
//# sourceMappingURL=aico-table-content.stories.js.map
|
package/dist/collection/components/content/aico-table-content/aico-table-content.stories.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"aico-table-content.stories.js","sourceRoot":"","sources":["../../../../src/components/content/aico-table-content/aico-table-content.stories.ts"],"names":[],"mappings":"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","sourcesContent":["import type { Meta, StoryObj } from '@storybook/web-components';\nimport type { TableContent } from '../../../model/article/content/TableContet';\nimport { JSX } from '../../../components';\n\nconst meta: Meta<JSX.AicoTableContent> = {\n component: 'aico-table-content',\n};\n\nexport default meta;\ntype Story = StoryObj;\n\nexport const Example: Story = {\n args: {\n content: {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n translations: [\n {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n title: 'Table title',\n additionalText: 'Additional text',\n },\n ],\n tableRows: [\n {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n isHeading: true,\n sort: 1,\n rowColumns: [\n {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n translations: [\n {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n columnData: 'Heading 1',\n },\n ],\n },\n {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n translations: [\n {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n columnData: 'Heading 2',\n },\n ],\n },\n ],\n },\n\n {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n isHeading: false,\n sort: 3,\n rowColumns: [\n {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n translations: [\n {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n columnData: 'Cell 1x2',\n },\n ],\n },\n {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n translations: [\n {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n columnData: 'Cell 2x2',\n },\n ],\n },\n ],\n },\n\n {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n isHeading: false,\n sort: 2,\n rowColumns: [\n {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n translations: [\n {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n columnData: 'Cell 1x1',\n },\n ],\n },\n {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n translations: [\n {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n columnData: 'Cell 2x1',\n },\n ],\n },\n ],\n },\n ],\n } as TableContent,\n },\n};\n"]}
|
package/dist/collection/components/content/aico-testimonial-content/aico-testimonial-content.css
ADDED
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
.star-rating {
|
|
2
|
+
font-size: 0;
|
|
3
|
+
white-space: nowrap;
|
|
4
|
+
height: 35px;
|
|
5
|
+
overflow: hidden;
|
|
6
|
+
position: relative;
|
|
7
|
+
background: url('data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4IiB3aWR0aD0iMjBweCIgaGVpZ2h0PSIyMHB4IiB2aWV3Qm94PSIwIDAgMjAgMjAiIGVuYWJsZS1iYWNrZ3JvdW5kPSJuZXcgMCAwIDIwIDIwIiB4bWw6c3BhY2U9InByZXNlcnZlIj48cG9seWdvbiBmaWxsPSIjREREREREIiBwb2ludHM9IjEwLDAgMTMuMDksNi41ODMgMjAsNy42MzkgMTUsMTIuNzY0IDE2LjE4LDIwIDEwLDE2LjU4MyAzLjgyLDIwIDUsMTIuNzY0IDAsNy42MzkgNi45MSw2LjU4MyAiLz48L3N2Zz4=');
|
|
8
|
+
background-size: contain;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
.star-rating i {
|
|
12
|
+
opacity: 0;
|
|
13
|
+
position: absolute;
|
|
14
|
+
left: 0;
|
|
15
|
+
top: 0;
|
|
16
|
+
height: 100%;
|
|
17
|
+
z-index: 1;
|
|
18
|
+
background: url('data:image/svg+xml;base64,PHN2ZyB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4IiB3aWR0aD0iMjBweCIgaGVpZ2h0PSIyMHB4IiB2aWV3Qm94PSIwIDAgMjAgMjAiIGVuYWJsZS1iYWNrZ3JvdW5kPSJuZXcgMCAwIDIwIDIwIiB4bWw6c3BhY2U9InByZXNlcnZlIj48cG9seWdvbiBmaWxsPSIjRkZERjg4IiBwb2ludHM9IjEwLDAgMTMuMDksNi41ODMgMjAsNy42MzkgMTUsMTIuNzY0IDE2LjE4LDIwIDEwLDE2LjU4MyAzLjgyLDIwIDUsMTIuNzY0IDAsNy42MzkgNi45MSw2LjU4MyAiLz48L3N2Zz4=');
|
|
19
|
+
background-size: contain;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.star-rating input {
|
|
23
|
+
opacity: 0;
|
|
24
|
+
display: inline-block;
|
|
25
|
+
height: 100%;
|
|
26
|
+
margin: 0;
|
|
27
|
+
padding: 0;
|
|
28
|
+
z-index: 2;
|
|
29
|
+
position: relative;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.star-rating input:hover + i,
|
|
33
|
+
.star-rating input:checked + i {
|
|
34
|
+
opacity: 1;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.star-rating i ~ i {
|
|
38
|
+
width: 40%;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.star-rating i ~ i ~ i {
|
|
42
|
+
width: 60%;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.star-rating i ~ i ~ i ~ i {
|
|
46
|
+
width: 80%;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.star-rating i ~ i ~ i ~ i ~ i {
|
|
50
|
+
width: 100%;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
.star-rating.star-5 {
|
|
54
|
+
width: 173px;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
.star-rating.star-5 input,
|
|
58
|
+
.star-rating.star-5 i {
|
|
59
|
+
width: 20%;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.star-rating.star-5 i ~ i {
|
|
63
|
+
width: 40%;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
.star-rating.star-5 i ~ i ~ i {
|
|
67
|
+
width: 60%;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.star-rating.star-5 i ~ i ~ i ~ i {
|
|
71
|
+
width: 80%;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.star-rating.star-5 i ~ i ~ i ~ i ~ i {
|
|
75
|
+
width: 100%;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
.star-rating.star-3 {
|
|
79
|
+
width: 150px;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.star-rating.star-3 input,
|
|
83
|
+
.star-rating.star-3 i {
|
|
84
|
+
width: 33.33%;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
.star-rating.star-3 i ~ i {
|
|
88
|
+
width: 66.66%;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
.star-rating.star-3 i ~ i ~ i {
|
|
92
|
+
width: 100%;
|
|
93
|
+
}
|
package/dist/collection/components/content/aico-testimonial-content/aico-testimonial-content.js
ADDED
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { Fragment, h } from "@stencil/core";
|
|
2
|
+
import ConditionalRender from "../../../utils/ConditionalRender";
|
|
3
|
+
import { strIsNullOrEmptyOrWhitespace } from "../../../utils/utils";
|
|
4
|
+
export class AicoTestimonialContent {
|
|
5
|
+
constructor() {
|
|
6
|
+
this.content = undefined;
|
|
7
|
+
}
|
|
8
|
+
render() {
|
|
9
|
+
return (h("div", { class: "card" }, h(ConditionalRender, { condition: !strIsNullOrEmptyOrWhitespace(this.content.testimonial.image) }, h("img", { class: "card-img-top", alt: "image", src: this.content.testimonial.image })), h("div", { class: "card-body" }, h("h2", { class: "card-title" }, this.content.testimonial.title), h("p", { class: "card-text" }, this.content.testimonial.text), h(ConditionalRender, { condition: this.content.testimonial.rating !== null }, h("div", { class: "star-rating star-5" }, Array.from({ length: this.content.testimonial.rating }, (_, i) => i + 1).map(index => {
|
|
10
|
+
return (h(Fragment, null, h("input", { type: "radio", id: `star${index}`, name: "rating", value: index }), h("i", { style: { opacity: this.content.testimonial.rating >= index ? '1' : '0' } })));
|
|
11
|
+
}))))));
|
|
12
|
+
}
|
|
13
|
+
static get is() { return "aico-testimonial-content"; }
|
|
14
|
+
static get encapsulation() { return "scoped"; }
|
|
15
|
+
static get originalStyleUrls() {
|
|
16
|
+
return {
|
|
17
|
+
"$": ["aico-testimonial-content.css"]
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
static get styleUrls() {
|
|
21
|
+
return {
|
|
22
|
+
"$": ["aico-testimonial-content.css"]
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
static get properties() {
|
|
26
|
+
return {
|
|
27
|
+
"content": {
|
|
28
|
+
"type": "unknown",
|
|
29
|
+
"mutable": false,
|
|
30
|
+
"complexType": {
|
|
31
|
+
"original": "TestimonialContent",
|
|
32
|
+
"resolved": "{ id: string | number; createdAt: Date; updatedAt: Date; } & { testimonial: { id: string | number; createdAt: Date; updatedAt: Date; locale: string; text?: string | null | undefined; title?: string | null | undefined; } & { image?: string | undefined; link?: string | undefined; rating?: number | undefined; }; }",
|
|
33
|
+
"references": {
|
|
34
|
+
"TestimonialContent": {
|
|
35
|
+
"location": "import",
|
|
36
|
+
"path": "../../../model/article/content/TestimonialContent",
|
|
37
|
+
"id": "src/model/article/content/TestimonialContent.ts::TestimonialContent"
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
},
|
|
41
|
+
"required": true,
|
|
42
|
+
"optional": false,
|
|
43
|
+
"docs": {
|
|
44
|
+
"tags": [],
|
|
45
|
+
"text": ""
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
};
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
//# sourceMappingURL=aico-testimonial-content.js.map
|
package/dist/collection/components/content/aico-testimonial-content/aico-testimonial-content.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"aico-testimonial-content.js","sourceRoot":"","sources":["../../../../src/components/content/aico-testimonial-content/aico-testimonial-content.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,eAAe,CAAC;AAE7D,OAAO,iBAAiB,MAAM,kCAAkC,CAAC;AACjE,OAAO,EAAE,4BAA4B,EAAE,MAAM,sBAAsB,CAAC;AAOpE,MAAM,OAAO,sBAAsB;;;;IAGjC,MAAM;QACJ,OAAO,CACL,WAAK,KAAK,EAAC,MAAM;YACf,EAAC,iBAAiB,IAAC,SAAS,EAAE,CAAC,4BAA4B,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,KAAK,CAAC;gBACzF,WAAK,KAAK,EAAC,cAAc,EAAC,GAAG,EAAC,OAAO,EAAC,GAAG,EAAE,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,KAAK,GAAQ,CAC/D;YACpB,WAAK,KAAK,EAAC,WAAW;gBACpB,UAAI,KAAK,EAAC,YAAY,IAAE,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,KAAK,CAAM;gBAC5D,SAAG,KAAK,EAAC,WAAW,IAAE,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,IAAI,CAAK;gBACxD,EAAC,iBAAiB,IAAC,SAAS,EAAE,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,MAAM,KAAK,IAAI;oBACpE,WAAK,KAAK,EAAC,oBAAoB,IAC5B,KAAK,CAAC,IAAI,CAAC,EAAE,MAAM,EAAE,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,MAAO,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE;wBACrF,OAAO,CACL,EAAC,QAAQ;4BACP,aAAO,IAAI,EAAC,OAAO,EAAC,EAAE,EAAE,OAAO,KAAK,EAAE,EAAE,IAAI,EAAC,QAAQ,EAAC,KAAK,EAAE,KAAK,GAAI;4BACtE,SAAG,KAAK,EAAE,EAAE,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,MAAO,IAAI,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,GAAG,EAAE,GAAM,CACzE,CACZ,CAAC;oBACJ,CAAC,CAAC,CACE,CACY,CAChB,CACF,CACP,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Fragment, Prop, h } from '@stencil/core';\nimport type { TestimonialContent } from '../../../model/article/content/TestimonialContent';\nimport ConditionalRender from '../../../utils/ConditionalRender';\nimport { strIsNullOrEmptyOrWhitespace } from '../../../utils/utils';\n\n@Component({\n tag: 'aico-testimonial-content',\n styleUrl: 'aico-testimonial-content.css',\n scoped: true,\n})\nexport class AicoTestimonialContent {\n @Prop() content!: TestimonialContent;\n\n render() {\n return (\n <div class=\"card\">\n <ConditionalRender condition={!strIsNullOrEmptyOrWhitespace(this.content.testimonial.image)}>\n <img class=\"card-img-top\" alt=\"image\" src={this.content.testimonial.image}></img>\n </ConditionalRender>\n <div class=\"card-body\">\n <h2 class=\"card-title\">{this.content.testimonial.title}</h2>\n <p class=\"card-text\">{this.content.testimonial.text}</p>\n <ConditionalRender condition={this.content.testimonial.rating !== null}>\n <div class=\"star-rating star-5\">\n {Array.from({ length: this.content.testimonial.rating! }, (_, i) => i + 1).map(index => {\n return (\n <Fragment>\n <input type=\"radio\" id={`star${index}`} name=\"rating\" value={index} />\n <i style={{ opacity: this.content.testimonial.rating! >= index ? '1' : '0' }}></i>\n </Fragment>\n );\n })}\n </div>\n </ConditionalRender>\n </div>\n </div>\n );\n }\n}\n"]}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
const meta = {
|
|
2
|
+
component: 'aico-testimonial-content',
|
|
3
|
+
};
|
|
4
|
+
export default meta;
|
|
5
|
+
export const Example = {
|
|
6
|
+
args: {
|
|
7
|
+
content: {
|
|
8
|
+
id: 1234,
|
|
9
|
+
createdAt: new Date(),
|
|
10
|
+
updatedAt: new Date(),
|
|
11
|
+
testimonial: {
|
|
12
|
+
id: 1234,
|
|
13
|
+
createdAt: new Date(),
|
|
14
|
+
updatedAt: new Date(),
|
|
15
|
+
title: 'Testimonial title',
|
|
16
|
+
text: 'Testimonial text',
|
|
17
|
+
rating: 3,
|
|
18
|
+
image: 'https://source.unsplash.com/random/320x240',
|
|
19
|
+
},
|
|
20
|
+
},
|
|
21
|
+
},
|
|
22
|
+
};
|
|
23
|
+
//# sourceMappingURL=aico-testimonial-content.stories.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"aico-testimonial-content.stories.js","sourceRoot":"","sources":["../../../../src/components/content/aico-testimonial-content/aico-testimonial-content.stories.ts"],"names":[],"mappings":"AAIA,MAAM,IAAI,GAAqC;IAC7C,SAAS,EAAE,0BAA0B;CACtC,CAAC;AAEF,eAAe,IAAI,CAAC;AAGpB,MAAM,CAAC,MAAM,OAAO,GAAU;IAC5B,IAAI,EAAE;QACJ,OAAO,EAAE;YACP,EAAE,EAAE,IAAI;YACR,SAAS,EAAE,IAAI,IAAI,EAAE;YACrB,SAAS,EAAE,IAAI,IAAI,EAAE;YACrB,WAAW,EAAE;gBACX,EAAE,EAAE,IAAI;gBACR,SAAS,EAAE,IAAI,IAAI,EAAE;gBACrB,SAAS,EAAE,IAAI,IAAI,EAAE;gBACrB,KAAK,EAAE,mBAAmB;gBAC1B,IAAI,EAAE,kBAAkB;gBACxB,MAAM,EAAE,CAAC;gBACT,KAAK,EAAE,4CAA4C;aACpD;SACoB;KACxB;CACF,CAAC","sourcesContent":["import type { Meta, StoryObj } from '@storybook/web-components';\nimport type { TestimonialContent } from '../../../model/article/content/TestimonialContent';\nimport { JSX } from '../../../components';\n\nconst meta: Meta<JSX.AicoTestimonialContent> = {\n component: 'aico-testimonial-content',\n};\n\nexport default meta;\ntype Story = StoryObj;\n\nexport const Example: Story = {\n args: {\n content: {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n testimonial: {\n id: 1234,\n createdAt: new Date(),\n updatedAt: new Date(),\n title: 'Testimonial title',\n text: 'Testimonial text',\n rating: 3,\n image: 'https://source.unsplash.com/random/320x240',\n },\n } as TestimonialContent,\n },\n};\n"]}
|
|
File without changes
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
import { h } from "@stencil/core";
|
|
2
|
+
import ConditionalRender from "../../../utils/ConditionalRender";
|
|
3
|
+
import ConditionalWrap from "../../../utils/ConditionalWrap";
|
|
4
|
+
import { getClass, strIsNullOrEmptyOrWhitespace } from "../../../utils/utils";
|
|
5
|
+
import "bootstrap";
|
|
6
|
+
export class AicoTextContent {
|
|
7
|
+
constructor() {
|
|
8
|
+
this.content = undefined;
|
|
9
|
+
}
|
|
10
|
+
render() {
|
|
11
|
+
var _a, _b, _c;
|
|
12
|
+
if (this.content.translations.length === 0) {
|
|
13
|
+
return h("aico-no-content", null);
|
|
14
|
+
}
|
|
15
|
+
const translation = this.content.translations.length > 0 ? this.content.translations[0] : null;
|
|
16
|
+
const contentStyles = {};
|
|
17
|
+
if (this.content.hasBackgroundColor) {
|
|
18
|
+
contentStyles['background-color'] = (_a = this.content.backgroundColor) !== null && _a !== void 0 ? _a : 'white';
|
|
19
|
+
contentStyles['color'] = (_b = this.content.textColor) !== null && _b !== void 0 ? _b : 'black';
|
|
20
|
+
contentStyles['width'] = '100%';
|
|
21
|
+
contentStyles['padding'] = '15px';
|
|
22
|
+
contentStyles['margin-top'] = '10px';
|
|
23
|
+
}
|
|
24
|
+
if (this.content.addBorder) {
|
|
25
|
+
contentStyles['border'] = `3px solid ${this.content.borderColor}`;
|
|
26
|
+
contentStyles['margin-top'] = '-3px';
|
|
27
|
+
}
|
|
28
|
+
if (this.content.alignmentEnabled) {
|
|
29
|
+
contentStyles['display'] = 'flex';
|
|
30
|
+
contentStyles['align-items'] = (_c = this.content.verticalAlign) !== null && _c !== void 0 ? _c : 'flex-start';
|
|
31
|
+
}
|
|
32
|
+
return (h(ConditionalRender, { condition: translation !== null }, h(ConditionalWrap, { condition: !strIsNullOrEmptyOrWhitespace(translation.promptText), wrap: children => (h("div", { class: "accordion", id: "aico-text-content" }, h("div", { class: "accordion-item" }, h("h2", { class: "accordion-header", id: "heading" }, h("button", { class: "accordion-button collapsed", type: "button", "data-bs-toggle": "collapse", "data-bs-target": "#collapse", "aria-expanded": "false", "aria-controls": "collapse" }, translation.promptText)), h("div", { id: "collapse", class: "accordion-collapse collapse", "aria-labelledby": "heading", "data-bs-parent": "#aico-text-content" }, h("div", { class: "accordion-body" }, children))))) }, h("div", { class: "card", style: contentStyles }, h("div", { class: "card-body w-100 border-0" }, h("aico-title-content", { class: "card-title", content: this.makeTitleContent(translation) }), h(ConditionalRender, { condition: this.shouldDisplayTextAndPicture(translation) }, h("div", { class: "row g-4" }, h("div", { class: getClass({
|
|
33
|
+
'col-md-8': true,
|
|
34
|
+
'order-1': this.content.picturePosition === 'right',
|
|
35
|
+
'order-2': this.content.picturePosition === 'left',
|
|
36
|
+
}) }, this.getTextComponent(translation)), h("div", { class: getClass({
|
|
37
|
+
'col-md-4 justify-content-center': true,
|
|
38
|
+
'order-2': this.content.picturePosition === 'right',
|
|
39
|
+
'order-1': this.content.picturePosition === 'left',
|
|
40
|
+
}) }, this.getImageComponent(translation)))), h(ConditionalRender, { condition: this.shouldDisplayOnlyPicture(translation) }, this.getImageComponent(translation)), h(ConditionalRender, { condition: this.shouldDisplayOnlyText(translation) }, this.getTextComponent(translation)))))));
|
|
41
|
+
}
|
|
42
|
+
getImageComponent(translation) {
|
|
43
|
+
var _a;
|
|
44
|
+
const imageStyles = {};
|
|
45
|
+
if (this.content.focusXPercentage && this.content.focusYCoordinate) {
|
|
46
|
+
imageStyles['object-position'] = `${this.content.focusXPercentage}% ${this.content.focusYPercentage}%`;
|
|
47
|
+
}
|
|
48
|
+
return (h("div", { class: "card text-bg-dark text-white" }, h("img", { class: "card-img img-fluid object-fit-contain", src: (_a = translation.optimizedPicture) !== null && _a !== void 0 ? _a : translation.picture }), h(ConditionalRender, { condition: !strIsNullOrEmptyOrWhitespace(translation.pictureLabel) }, h("div", { class: "card-img-overlay" }, h("p", { class: getClass({
|
|
49
|
+
'card-text': true,
|
|
50
|
+
'text-end': this.content.pictureLabelPosition === 'right',
|
|
51
|
+
'text-center': this.content.pictureLabelPosition === 'center',
|
|
52
|
+
}) }, translation.pictureLabel)))));
|
|
53
|
+
}
|
|
54
|
+
getTextComponent(translation) {
|
|
55
|
+
const textStyles = { 'line-height': '1.3', 'white-space': 'pre-line' };
|
|
56
|
+
if (this.content.fontSize) {
|
|
57
|
+
textStyles['font-size'] = `${this.content.fontSize}px`;
|
|
58
|
+
}
|
|
59
|
+
if (this.content.fontFamily) {
|
|
60
|
+
textStyles['font-family'] = this.content.fontFamily;
|
|
61
|
+
}
|
|
62
|
+
if (this.content.shouldJustifyText) {
|
|
63
|
+
textStyles['text-align'] = 'justify';
|
|
64
|
+
textStyles['text-justify'] = 'inner-word';
|
|
65
|
+
}
|
|
66
|
+
return (h("p", { class: "card-text", style: textStyles }, translation.text));
|
|
67
|
+
}
|
|
68
|
+
makeTitleContent(translation) {
|
|
69
|
+
var _a;
|
|
70
|
+
return {
|
|
71
|
+
id: this.content.id,
|
|
72
|
+
createdAt: this.content.createdAt,
|
|
73
|
+
updatedAt: this.content.updatedAt,
|
|
74
|
+
hasUnderscore: false,
|
|
75
|
+
size: (_a = this.content.titleSize) !== null && _a !== void 0 ? _a : 'h1',
|
|
76
|
+
titleColor: this.content.textColor,
|
|
77
|
+
translations: [Object.assign({}, translation)],
|
|
78
|
+
};
|
|
79
|
+
}
|
|
80
|
+
shouldDisplayTextAndPicture(translation) {
|
|
81
|
+
return !strIsNullOrEmptyOrWhitespace(translation.text) && (!strIsNullOrEmptyOrWhitespace(translation.optimizedPicture) || !strIsNullOrEmptyOrWhitespace(translation.picture));
|
|
82
|
+
}
|
|
83
|
+
shouldDisplayOnlyPicture(translation) {
|
|
84
|
+
return strIsNullOrEmptyOrWhitespace(translation.text) && (!strIsNullOrEmptyOrWhitespace(translation.optimizedPicture) || !strIsNullOrEmptyOrWhitespace(translation.picture));
|
|
85
|
+
}
|
|
86
|
+
shouldDisplayOnlyText(translation) {
|
|
87
|
+
return !strIsNullOrEmptyOrWhitespace(translation.text) && strIsNullOrEmptyOrWhitespace(translation.optimizedPicture) && strIsNullOrEmptyOrWhitespace(translation.picture);
|
|
88
|
+
}
|
|
89
|
+
static get is() { return "aico-text-content"; }
|
|
90
|
+
static get encapsulation() { return "scoped"; }
|
|
91
|
+
static get originalStyleUrls() {
|
|
92
|
+
return {
|
|
93
|
+
"$": ["aico-text-content.css", "../content-styles.css"]
|
|
94
|
+
};
|
|
95
|
+
}
|
|
96
|
+
static get styleUrls() {
|
|
97
|
+
return {
|
|
98
|
+
"$": ["aico-text-content.css", "../content-styles.css"]
|
|
99
|
+
};
|
|
100
|
+
}
|
|
101
|
+
static get properties() {
|
|
102
|
+
return {
|
|
103
|
+
"content": {
|
|
104
|
+
"type": "unknown",
|
|
105
|
+
"mutable": false,
|
|
106
|
+
"complexType": {
|
|
107
|
+
"original": "TextContent",
|
|
108
|
+
"resolved": "{ id: string | number; createdAt: Date; updatedAt: Date; } & { translations: TextContentTranslation[]; sort?: number | undefined; picturePosition?: string | undefined; pictureSize?: string | undefined; pictureLabelPosition?: string | undefined; titleSize?: string | undefined; fontSize?: string | undefined; fontFamily?: string | undefined; verticalAlign: string; alignmentEnabled: boolean; hasBackgroundColor: boolean; backgroundColor?: string | undefined; shouldJustifyText: boolean; textColor?: string | undefined; isButtonRightUnderText: boolean; isContentDisplayedAsPrompt: boolean; pictureFontOption: string; addBorder: boolean; borderColor?: string | undefined; focusXCoordinate?: number | undefined; focusYCoordinate?: number | undefined; focusXPercentage?: number | undefined; focusYPercentage?: number | undefined; promptText?: string | undefined; link?: string | undefined; picture?: string | undefined; IMPORTANT?: string | undefined; }",
|
|
109
|
+
"references": {
|
|
110
|
+
"TextContent": {
|
|
111
|
+
"location": "import",
|
|
112
|
+
"path": "../../../model/article/content/TextContent",
|
|
113
|
+
"id": "src/model/article/content/TextContent.ts::TextContent"
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
},
|
|
117
|
+
"required": true,
|
|
118
|
+
"optional": false,
|
|
119
|
+
"docs": {
|
|
120
|
+
"tags": [],
|
|
121
|
+
"text": ""
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
};
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
//# sourceMappingURL=aico-text-content.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"aico-text-content.js","sourceRoot":"","sources":["../../../../src/components/content/aico-text-content/aico-text-content.tsx"],"names":[],"mappings":"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","sourcesContent":["import { Component, Prop, VNode, h } from '@stencil/core';\nimport ConditionalRender from '../../../utils/ConditionalRender';\nimport ConditionalWrap from '../../../utils/ConditionalWrap';\nimport type { TextContent, TextContentTranslation } from '../../../model/article/content/TextContent';\nimport type { TitleContent } from '../../../model/article/content/TitleContent';\nimport { getClass, strIsNullOrEmptyOrWhitespace } from '../../../utils/utils';\nimport 'bootstrap';\n\n@Component({\n tag: 'aico-text-content',\n styleUrls: ['aico-text-content.css', '../content-styles.css'],\n scoped: true,\n})\nexport class AicoTextContent {\n @Prop() content!: TextContent;\n\n render() {\n if (this.content.translations.length === 0) {\n return <aico-no-content />;\n }\n\n const translation = this.content.translations.length > 0 ? this.content.translations[0] : null;\n const contentStyles: { [key: string]: string | undefined } = {};\n\n if (this.content.hasBackgroundColor) {\n contentStyles['background-color'] = this.content.backgroundColor ?? 'white';\n contentStyles['color'] = this.content.textColor ?? 'black';\n contentStyles['width'] = '100%';\n contentStyles['padding'] = '15px';\n contentStyles['margin-top'] = '10px';\n }\n\n if (this.content.addBorder) {\n contentStyles['border'] = `3px solid ${this.content.borderColor}`;\n contentStyles['margin-top'] = '-3px';\n }\n\n if (this.content.alignmentEnabled) {\n contentStyles['display'] = 'flex';\n contentStyles['align-items'] = this.content.verticalAlign ?? 'flex-start';\n }\n\n return (\n <ConditionalRender condition={translation !== null}>\n <ConditionalWrap\n condition={!strIsNullOrEmptyOrWhitespace(translation!.promptText)}\n wrap={children => (\n <div class=\"accordion\" id=\"aico-text-content\">\n <div class=\"accordion-item\">\n <h2 class=\"accordion-header\" id=\"heading\">\n <button class=\"accordion-button collapsed\" type=\"button\" data-bs-toggle=\"collapse\" data-bs-target=\"#collapse\" aria-expanded=\"false\" aria-controls=\"collapse\">\n {translation!.promptText}\n </button>\n </h2>\n <div id=\"collapse\" class=\"accordion-collapse collapse\" aria-labelledby=\"heading\" data-bs-parent=\"#aico-text-content\">\n <div class=\"accordion-body\">{children}</div>\n </div>\n </div>\n </div>\n )}\n >\n <div class=\"card\" style={contentStyles}>\n <div class=\"card-body w-100 border-0\">\n <aico-title-content class=\"card-title\" content={this.makeTitleContent(translation!)} />\n <ConditionalRender condition={this.shouldDisplayTextAndPicture(translation!)}>\n <div class=\"row g-4\">\n <div\n class={getClass({\n 'col-md-8': true,\n 'order-1': this.content.picturePosition === 'right',\n 'order-2': this.content.picturePosition === 'left',\n })}\n >\n {this.getTextComponent(translation!)}\n </div>\n <div\n class={getClass({\n 'col-md-4 justify-content-center': true,\n 'order-2': this.content.picturePosition === 'right',\n 'order-1': this.content.picturePosition === 'left',\n })}\n >\n {this.getImageComponent(translation!)}\n </div>\n </div>\n </ConditionalRender>\n <ConditionalRender condition={this.shouldDisplayOnlyPicture(translation!)}>{this.getImageComponent(translation!)}</ConditionalRender>\n <ConditionalRender condition={this.shouldDisplayOnlyText(translation!)}>{this.getTextComponent(translation!)}</ConditionalRender>\n </div>\n </div>\n </ConditionalWrap>\n </ConditionalRender>\n );\n }\n\n private getImageComponent(translation: TextContentTranslation): VNode {\n const imageStyles: { [key: string]: string | undefined } = {};\n\n if (this.content.focusXPercentage && this.content.focusYCoordinate) {\n imageStyles['object-position'] = `${this.content.focusXPercentage}% ${this.content.focusYPercentage}%`;\n }\n\n return (\n <div class=\"card text-bg-dark text-white\">\n <img class=\"card-img img-fluid object-fit-contain\" src={translation.optimizedPicture ?? translation.picture} />\n <ConditionalRender condition={!strIsNullOrEmptyOrWhitespace(translation.pictureLabel)}>\n <div class=\"card-img-overlay\">\n <p\n class={getClass({\n 'card-text': true,\n 'text-end': this.content.pictureLabelPosition === 'right',\n 'text-center': this.content.pictureLabelPosition === 'center',\n })}\n >\n {translation.pictureLabel}\n </p>\n </div>\n </ConditionalRender>\n </div>\n );\n }\n\n private getTextComponent(translation: TextContentTranslation): VNode {\n const textStyles: { [key: string]: string | undefined } = { 'line-height': '1.3', 'white-space': 'pre-line' };\n if (this.content.fontSize) {\n textStyles['font-size'] = `${this.content.fontSize}px`;\n }\n\n if (this.content.fontFamily) {\n textStyles['font-family'] = this.content.fontFamily;\n }\n\n if (this.content.shouldJustifyText) {\n textStyles['text-align'] = 'justify';\n textStyles['text-justify'] = 'inner-word';\n }\n\n return (\n <p class=\"card-text\" style={textStyles}>\n {translation.text}\n </p>\n );\n }\n\n private makeTitleContent(translation: TextContentTranslation): TitleContent {\n return {\n id: this.content.id,\n createdAt: this.content.createdAt,\n updatedAt: this.content.updatedAt,\n hasUnderscore: false,\n size: this.content.titleSize ?? 'h1',\n titleColor: this.content.textColor,\n translations: [{ ...translation }],\n };\n }\n\n private shouldDisplayTextAndPicture(translation: TextContentTranslation): boolean {\n return !strIsNullOrEmptyOrWhitespace(translation.text) && (!strIsNullOrEmptyOrWhitespace(translation.optimizedPicture) || !strIsNullOrEmptyOrWhitespace(translation.picture));\n }\n\n private shouldDisplayOnlyPicture(translation: TextContentTranslation): boolean {\n return strIsNullOrEmptyOrWhitespace(translation.text) && (!strIsNullOrEmptyOrWhitespace(translation.optimizedPicture) || !strIsNullOrEmptyOrWhitespace(translation.picture));\n }\n\n private shouldDisplayOnlyText(translation: TextContentTranslation): boolean {\n return !strIsNullOrEmptyOrWhitespace(translation.text) && strIsNullOrEmptyOrWhitespace(translation.optimizedPicture) && strIsNullOrEmptyOrWhitespace(translation.picture);\n }\n}\n"]}
|
|
@@ -0,0 +1,173 @@
|
|
|
1
|
+
const meta = {
|
|
2
|
+
component: 'aico-text-content',
|
|
3
|
+
};
|
|
4
|
+
export default meta;
|
|
5
|
+
export const Example = {
|
|
6
|
+
args: {
|
|
7
|
+
content: {
|
|
8
|
+
id: 1234,
|
|
9
|
+
createdAt: new Date(),
|
|
10
|
+
updatedAt: new Date(),
|
|
11
|
+
translations: [
|
|
12
|
+
{
|
|
13
|
+
id: 1234,
|
|
14
|
+
createdAt: new Date(),
|
|
15
|
+
updatedAt: new Date(),
|
|
16
|
+
title: 'Howdy',
|
|
17
|
+
promptText: 'Prompt text',
|
|
18
|
+
locale: 'en-GB',
|
|
19
|
+
},
|
|
20
|
+
],
|
|
21
|
+
titleSize: 'h1',
|
|
22
|
+
alignmentEnabled: true,
|
|
23
|
+
hasBackgroundColor: true,
|
|
24
|
+
backgroundColor: 'red',
|
|
25
|
+
shouldJustifyText: true,
|
|
26
|
+
textColor: 'white',
|
|
27
|
+
isButtonRightUnderText: true,
|
|
28
|
+
isContentDisplayedAsPrompt: false,
|
|
29
|
+
pictureFontOption: 'H1',
|
|
30
|
+
addBorder: true,
|
|
31
|
+
borderColor: 'blue',
|
|
32
|
+
},
|
|
33
|
+
},
|
|
34
|
+
};
|
|
35
|
+
export const NoPrompt = {
|
|
36
|
+
args: {
|
|
37
|
+
content: {
|
|
38
|
+
id: 1234,
|
|
39
|
+
createdAt: new Date(),
|
|
40
|
+
updatedAt: new Date(),
|
|
41
|
+
translations: [
|
|
42
|
+
{
|
|
43
|
+
id: 1234,
|
|
44
|
+
createdAt: new Date(),
|
|
45
|
+
updatedAt: new Date(),
|
|
46
|
+
title: 'Howdy',
|
|
47
|
+
promptText: null,
|
|
48
|
+
locale: 'en-GB',
|
|
49
|
+
picture: 'https://source.unsplash.com/random/800x600',
|
|
50
|
+
pictureLabel: 'Picture label',
|
|
51
|
+
text: 'Foo\nBar\nBaz',
|
|
52
|
+
},
|
|
53
|
+
],
|
|
54
|
+
picturePosition: 'center',
|
|
55
|
+
pictureSize: 'small',
|
|
56
|
+
pictureLabelPosition: 'left',
|
|
57
|
+
alignmentEnabled: true,
|
|
58
|
+
hasBackgroundColor: true,
|
|
59
|
+
backgroundColor: 'red',
|
|
60
|
+
shouldJustifyText: true,
|
|
61
|
+
textColor: 'white',
|
|
62
|
+
isButtonRightUnderText: true,
|
|
63
|
+
isContentDisplayedAsPrompt: false,
|
|
64
|
+
pictureFontOption: 'H1',
|
|
65
|
+
addBorder: true,
|
|
66
|
+
borderColor: 'blue',
|
|
67
|
+
},
|
|
68
|
+
},
|
|
69
|
+
};
|
|
70
|
+
export const TextAndImage = {
|
|
71
|
+
args: {
|
|
72
|
+
content: {
|
|
73
|
+
id: 1234,
|
|
74
|
+
createdAt: new Date(),
|
|
75
|
+
updatedAt: new Date(),
|
|
76
|
+
translations: [
|
|
77
|
+
{
|
|
78
|
+
id: 1234,
|
|
79
|
+
createdAt: new Date(),
|
|
80
|
+
updatedAt: new Date(),
|
|
81
|
+
title: 'Howdy',
|
|
82
|
+
promptText: 'Prompt text',
|
|
83
|
+
locale: 'en-GB',
|
|
84
|
+
picture: 'https://source.unsplash.com/random/800x600',
|
|
85
|
+
pictureLabel: 'Picture label',
|
|
86
|
+
text: 'Foo\nBar\nBaz',
|
|
87
|
+
},
|
|
88
|
+
],
|
|
89
|
+
picturePosition: 'center',
|
|
90
|
+
pictureSize: 'small',
|
|
91
|
+
pictureLabelPosition: 'left',
|
|
92
|
+
alignmentEnabled: true,
|
|
93
|
+
hasBackgroundColor: true,
|
|
94
|
+
backgroundColor: 'red',
|
|
95
|
+
shouldJustifyText: true,
|
|
96
|
+
textColor: 'white',
|
|
97
|
+
isButtonRightUnderText: true,
|
|
98
|
+
isContentDisplayedAsPrompt: false,
|
|
99
|
+
pictureFontOption: 'H1',
|
|
100
|
+
addBorder: true,
|
|
101
|
+
borderColor: 'blue',
|
|
102
|
+
},
|
|
103
|
+
},
|
|
104
|
+
};
|
|
105
|
+
export const OnlyImage = {
|
|
106
|
+
args: {
|
|
107
|
+
content: {
|
|
108
|
+
id: 1234,
|
|
109
|
+
createdAt: new Date(),
|
|
110
|
+
updatedAt: new Date(),
|
|
111
|
+
translations: [
|
|
112
|
+
{
|
|
113
|
+
id: 1234,
|
|
114
|
+
createdAt: new Date(),
|
|
115
|
+
updatedAt: new Date(),
|
|
116
|
+
title: 'Howdy',
|
|
117
|
+
promptText: 'Prompt text',
|
|
118
|
+
locale: 'en-GB',
|
|
119
|
+
picture: 'https://source.unsplash.com/random/800x600',
|
|
120
|
+
pictureLabel: 'Picture label',
|
|
121
|
+
},
|
|
122
|
+
],
|
|
123
|
+
picturePosition: 'center',
|
|
124
|
+
pictureSize: 'small',
|
|
125
|
+
pictureLabelPosition: 'left',
|
|
126
|
+
alignmentEnabled: true,
|
|
127
|
+
hasBackgroundColor: true,
|
|
128
|
+
backgroundColor: 'red',
|
|
129
|
+
shouldJustifyText: true,
|
|
130
|
+
textColor: 'white',
|
|
131
|
+
isButtonRightUnderText: true,
|
|
132
|
+
isContentDisplayedAsPrompt: false,
|
|
133
|
+
pictureFontOption: 'H1',
|
|
134
|
+
addBorder: true,
|
|
135
|
+
borderColor: 'blue',
|
|
136
|
+
},
|
|
137
|
+
},
|
|
138
|
+
};
|
|
139
|
+
export const OnlyText = {
|
|
140
|
+
args: {
|
|
141
|
+
content: {
|
|
142
|
+
id: 1234,
|
|
143
|
+
createdAt: new Date(),
|
|
144
|
+
updatedAt: new Date(),
|
|
145
|
+
translations: [
|
|
146
|
+
{
|
|
147
|
+
id: 1234,
|
|
148
|
+
createdAt: new Date(),
|
|
149
|
+
updatedAt: new Date(),
|
|
150
|
+
title: 'Howdy',
|
|
151
|
+
promptText: 'Prompt text',
|
|
152
|
+
locale: 'en-GB',
|
|
153
|
+
text: 'Foo\nBar\nBaz',
|
|
154
|
+
pictureLabel: 'Picture label',
|
|
155
|
+
},
|
|
156
|
+
],
|
|
157
|
+
picturePosition: 'center',
|
|
158
|
+
pictureSize: 'small',
|
|
159
|
+
pictureLabelPosition: 'left',
|
|
160
|
+
alignmentEnabled: true,
|
|
161
|
+
hasBackgroundColor: true,
|
|
162
|
+
backgroundColor: 'red',
|
|
163
|
+
shouldJustifyText: true,
|
|
164
|
+
textColor: 'white',
|
|
165
|
+
isButtonRightUnderText: true,
|
|
166
|
+
isContentDisplayedAsPrompt: false,
|
|
167
|
+
pictureFontOption: 'H1',
|
|
168
|
+
addBorder: true,
|
|
169
|
+
borderColor: 'blue',
|
|
170
|
+
},
|
|
171
|
+
},
|
|
172
|
+
};
|
|
173
|
+
//# sourceMappingURL=aico-text-content.stories.js.map
|