@ilo-org/twig 0.17.0 → 0.17.1
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/components/accordion/accordion.behavior.js +1 -0
- package/dist/components/accordion/accordion.css +1 -0
- package/dist/components/accordion/accordion.twig +16 -0
- package/dist/components/accordion/accordion.wingsuit.yml +77 -0
- package/dist/components/accordion-item/accordion-item.twig +22 -0
- package/dist/components/breadcrumb/breadcrumb.behavior.js +1 -0
- package/dist/components/breadcrumb/breadcrumb.css +1 -0
- package/dist/components/breadcrumb/breadcrumb.twig +43 -0
- package/dist/components/breadcrumb/breadcrumb.wingsuit.yml +36 -0
- package/dist/components/button/button.css +1 -0
- package/dist/components/button/button.twig +23 -0
- package/dist/components/button/button.wingsuit.yml +114 -0
- package/dist/components/callout/callout.behavior.js +1 -0
- package/dist/components/callout/callout.css +1 -0
- package/dist/components/callout/callout.twig +41 -0
- package/dist/components/callout/callout.wingsuit.yml +72 -0
- package/dist/components/card/card.css +1 -0
- package/dist/components/card/card.twig +24 -0
- package/dist/components/card/card.wingsuit.yml +227 -0
- package/dist/components/card_data/card_data.twig +101 -0
- package/dist/components/card_data/card_data.wingsuit.yml +135 -0
- package/dist/components/card_detail/card_detail.twig +37 -0
- package/dist/components/card_detail/card_detail.wingsuit.yml +71 -0
- package/dist/components/card_factlist/card_factlist.twig +21 -0
- package/dist/components/card_factlist/card_factlist.wingsuit.yml +46 -0
- package/dist/components/card_feature/card_feature.twig +39 -0
- package/dist/components/card_feature/card_feature.wingsuit.yml +80 -0
- package/dist/components/card_multilink/card_multilink.twig +45 -0
- package/dist/components/card_multilink/card_multilink.wingsuit.yml +91 -0
- package/dist/components/card_promo/card_promo.twig +35 -0
- package/dist/components/card_promo/card_promo.wingsuit.yml +71 -0
- package/dist/components/card_stat/card_stat.twig +24 -0
- package/dist/components/card_stat/card_stat.wingsuit.yml +44 -0
- package/dist/components/card_text/card_text.twig +35 -0
- package/dist/components/card_text/card_text.wingsuit.yml +57 -0
- package/dist/components/cardgroup/cardgroup.css +1 -0
- package/dist/components/cardgroup/cardgroup.twig +46 -0
- package/dist/components/cardgroup/cardgroup.wingsuit.yml +158 -0
- package/dist/components/checkbox/checkbox.css +1 -0
- package/dist/components/checkbox/checkbox.twig +17 -0
- package/dist/components/checkbox/checkbox.wingsuit.yml +83 -0
- package/dist/components/container/container.css +1 -0
- package/dist/components/contextmenu/contextmenu.css +1 -0
- package/dist/components/contextmenu/contextmenu.twig +12 -0
- package/dist/components/contextmenu/contextmenu.wingsuit.yml +24 -0
- package/dist/components/credit/credit.css +1 -0
- package/dist/components/datacard/datacard.css +1 -0
- package/dist/components/datepicker/datepicker.css +1 -0
- package/dist/components/datepicker/datepicker.twig +20 -0
- package/dist/components/datepicker/datepicker.wingsuit.yml +72 -0
- package/dist/components/detailcard/detailcard.css +1 -0
- package/dist/components/dropdown/dropdown.css +1 -0
- package/dist/components/dropdown/dropdown.twig +22 -0
- package/dist/components/dropdown/dropdown.wingsuit.yml +100 -0
- package/dist/components/empty/empty.css +1 -0
- package/dist/components/factlistcard/factlistcard.css +1 -0
- package/dist/components/featurecard/featurecard.css +1 -0
- package/dist/components/fieldset/fieldset.css +1 -0
- package/dist/components/fieldset/fieldset.twig +70 -0
- package/dist/components/file-upload/file-upload.css +1 -0
- package/dist/components/fileupload/fileupload.behavior.js +1 -0
- package/dist/components/fileupload/fileupload.twig +20 -0
- package/dist/components/fileupload/fileupload.wingsuit.yml +94 -0
- package/dist/components/footer/footer.css +1 -0
- package/dist/components/footer/footer.twig +63 -0
- package/dist/components/footer/footer.wingsuit.yml +106 -0
- package/dist/components/form/form.css +1 -0
- package/dist/components/form/form.twig +19 -0
- package/dist/components/form/form.wingsuit.yml +205 -0
- package/dist/components/formcontrol/formcontrol.css +1 -0
- package/dist/components/formcontrol/formcontrol.twig +89 -0
- package/dist/components/heading/heading.css +1 -0
- package/dist/components/hero/hero.css +1 -0
- package/dist/components/hero/hero.twig +65 -0
- package/dist/components/hero/hero.wingsuit.yml +182 -0
- package/dist/components/herocard/herocard.css +1 -0
- package/dist/components/herocard/herocard.twig +30 -0
- package/dist/components/herocard/herocard.wingsuit.yml +71 -0
- package/dist/components/icon/icon.behavior.js +1 -0
- package/dist/components/icon/icon.css +1 -0
- package/dist/components/icon/icon.twig +4 -0
- package/dist/components/icon/icon.wingsuit.yml +29 -0
- package/dist/components/image/image.css +1 -0
- package/dist/components/image/image.twig +29 -0
- package/dist/components/image/image.wingsuit.yml +57 -0
- package/dist/components/input/input.css +1 -0
- package/dist/components/input/input.twig +10 -0
- package/dist/components/link/link.css +1 -0
- package/dist/components/link/link.twig +8 -0
- package/dist/components/link/link.wingsuit.yml +36 -0
- package/dist/components/linklist/linklist.behavior.js +1 -0
- package/dist/components/linklist/linklist.css +1 -0
- package/dist/components/linklist/linklist.twig +26 -0
- package/dist/components/linklist/linklist.wingsuit.yml +55 -0
- package/dist/components/list/list.css +1 -0
- package/dist/components/list/list.twig +35 -0
- package/dist/components/list/list.wingsuit.yml +60 -0
- package/dist/components/list-item/list-item.twig +6 -0
- package/dist/components/list-item/list-item.wingsuit.yml +19 -0
- package/dist/components/loading/loading.behavior.js +1 -0
- package/dist/components/loading/loading.css +1 -0
- package/dist/components/loading/loading.twig +8 -0
- package/dist/components/loading/loading.wingsuit.yml +39 -0
- package/dist/components/localnav/localnav.twig +86 -0
- package/dist/components/localnav/localnav.wingsuit.yml +88 -0
- package/dist/components/logo/logo.css +1 -0
- package/dist/components/logogrid/logogrid.css +1 -0
- package/dist/components/logogrid/logogrid.twig +17 -0
- package/dist/components/logogrid/logogrid.wingsuit.yml +45 -0
- package/dist/components/modal/modal.behavior.js +1 -0
- package/dist/components/modal/modal.css +1 -0
- package/dist/components/modal/modal.twig +20 -0
- package/dist/components/modal/modal.wingsuit.yml +61 -0
- package/dist/components/multilinkcard/multilinkcard.css +1 -0
- package/dist/components/navigation/navigation.behavior.js +1 -0
- package/dist/components/navigation/navigation.css +1 -0
- package/dist/components/navigation/navigation.twig +171 -0
- package/dist/components/navigation/navigation.wingsuit.yml +126 -0
- package/dist/components/notification/notification.behavior.js +1 -0
- package/dist/components/notification/notification.css +1 -0
- package/dist/components/notification/notification.twig +18 -0
- package/dist/components/notification/notification.wingsuit.yml +59 -0
- package/dist/components/numberpicker/numberpicker.twig +16 -0
- package/dist/components/numberpicker/numberpicker.wingsuit.yml +91 -0
- package/dist/components/pagination/pagination.css +1 -0
- package/dist/components/pagination/pagination.twig +49 -0
- package/dist/components/pagination/pagination.wingsuit.yml +75 -0
- package/dist/components/picture/picture.twig +21 -0
- package/dist/components/polyfill/polyfill.twig +10 -0
- package/dist/components/profile/profile.css +1 -0
- package/dist/components/profile/profile.twig +26 -0
- package/dist/components/profile/profile.wingsuit.yml +46 -0
- package/dist/components/promocard/promocard.css +1 -0
- package/dist/components/radio/radio.css +1 -0
- package/dist/components/radio/radio.twig +23 -0
- package/dist/components/radio/radio.wingsuit.yml +83 -0
- package/dist/components/readmore/readmore.behavior.js +1 -0
- package/dist/components/readmore/readmore.css +1 -0
- package/dist/components/readmore/readmore.twig +16 -0
- package/dist/components/readmore/readmore.wingsuit.yml +37 -0
- package/dist/components/richtext/richtext.css +1 -0
- package/dist/components/richtext/richtext.twig +6 -0
- package/dist/components/richtext/richtext.wingsuit.yml +13 -0
- package/dist/components/search/search.behavior.js +1 -0
- package/dist/components/search/search.twig +31 -0
- package/dist/components/search/search.wingsuit.yml +89 -0
- package/dist/components/searchfield/searchfield.css +1 -0
- package/dist/components/socialmedia/socialmedia.css +1 -0
- package/dist/components/socialmedia/socialmedia.twig +17 -0
- package/dist/components/socialmedia/socialmedia.wingsuit.yml +59 -0
- package/dist/components/statcard/statcard.css +1 -0
- package/dist/components/table/table.behavior.js +1 -0
- package/dist/components/table/table.css +1 -0
- package/dist/components/table/table.twig +39 -0
- package/dist/components/table/table.wingsuit.yml +112 -0
- package/dist/components/tableofcontents/tableofcontents.behavior.js +1 -0
- package/dist/components/tableofcontents/tableofcontents.css +1 -0
- package/dist/components/tableofcontents/tableofcontents.twig +47 -0
- package/dist/components/tableofcontents/tableofcontents.wingsuit.yml +44 -0
- package/dist/components/tabs/tabs.behavior.js +1 -0
- package/dist/components/tabs/tabs.css +1 -0
- package/dist/components/tabs/tabs.twig +26 -0
- package/dist/components/tabs/tabs.wingsuit.yml +169 -0
- package/dist/components/tag/tag.behavior.js +1 -0
- package/dist/components/tag/tag.css +1 -0
- package/dist/components/tag/tag.twig +30 -0
- package/dist/components/tag/tag.wingsuit.yml +43 -0
- package/dist/components/tags/tags.twig +15 -0
- package/dist/components/tags/tags.wingsuit.yml +45 -0
- package/dist/components/textarea/textarea.css +1 -0
- package/dist/components/textarea/textarea.twig +14 -0
- package/dist/components/textarea/textarea.wingsuit.yml +126 -0
- package/dist/components/textcard/textcard.css +1 -0
- package/dist/components/textinput/textinput.css +1 -0
- package/dist/components/textinput/textinput.twig +14 -0
- package/dist/components/textinput/textinput.wingsuit.yml +86 -0
- package/dist/components/toggle/toggle.css +1 -0
- package/dist/components/toggle/toggle.twig +36 -0
- package/dist/components/toggle/toggle.wingsuit.yml +94 -0
- package/dist/components/tooltip/tooltip.behavior.js +1 -0
- package/dist/components/tooltip/tooltip.css +1 -0
- package/dist/components/tooltip/tooltip.twig +14 -0
- package/dist/components/tooltip/tooltip.wingsuit.yml +53 -0
- package/dist/components/video/video.behavior.js +16 -0
- package/dist/components/video/video.css +1 -0
- package/dist/components/video/video.twig +18 -0
- package/dist/components/video/video.wingsuit.yml +82 -0
- package/dist/components/videoplayer/videoplayer.twig +8 -0
- package/dist/global/styles.css +2 -0
- package/package.json +13 -9
- package/.browserslistrc +0 -4
- package/.eslintrc.js +0 -25
- package/.stylelintignore +0 -9
- package/.stylelintrc +0 -19
- package/.turbo/turbo-build:lib.log +0 -71
- package/CHANGELOG.md +0 -1036
- package/apps/storybook/assets.js +0 -10
- package/apps/storybook/main.js +0 -27
- package/apps/storybook/manager-head.html +0 -92
- package/apps/storybook/manager.js +0 -7
- package/apps/storybook/patterns/colors.stories.mdx +0 -23
- package/apps/storybook/patterns/intro.stories.mdx +0 -184
- package/apps/storybook/patterns/typeset.stories.mdx +0 -32
- package/apps/storybook/patterns/welcome.stories.mdx +0 -33
- package/apps/storybook/preview-body.html +0 -4
- package/apps/storybook/preview-head.html +0 -5
- package/apps/storybook/preview.js +0 -36
- package/apps/storybook/styles.scss +0 -25
- package/apps/storybook/theme.js +0 -46
- package/apps/storybook/welcome.scss +0 -131
- package/babel.config.js +0 -16
- package/copystyles.js +0 -16
- package/copytemplates.js +0 -27
- package/images/fao-logo.svg +0 -195
- package/images/favicon.ico +0 -0
- package/images/hero.jpg +0 -0
- package/images/ilo-dg.jpg +0 -0
- package/images/ilo-headquarters.jpg +0 -0
- package/images/large.jpg +0 -0
- package/images/logo_en_horizontal_blue.svg +0 -893
- package/images/media-file-poster.jpg +0 -0
- package/images/medium.jpg +0 -0
- package/images/publication.jpg +0 -0
- package/images/small.jpg +0 -0
- package/images/twig.svg +0 -6
- package/images/unhcr-logo.svg +0 -1
- package/images/unicef-logo.png +0 -0
- package/images/video-example.mp4 +0 -0
- package/images/wfp-logo.svg +0 -1
- package/images/who-logo.svg +0 -1
- package/images/youtube-video-poster.avif +0 -0
- package/importprefix.js +0 -20
- package/importsvgs.js +0 -5
- package/jest.config.js +0 -18
- package/postcss.config.js +0 -6
- package/rollup.config.js +0 -31
- package/wingsuit.config.js +0 -28
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@charset "UTF-8";.ilo--link-list--headline{font-size:23.32px;line-height:29.15px;margin-bottom:1.0404340836rem}.ilo--link-list--headline,.ilo--link-list--links--headline{font-family:Overpass,Noto Sans,Noto Sans CJK JP,Yu Gothic,Hiragino Sans,TakaoPGothic,PingFang SC,Microsoft YaHei,微软雅黑,sans-serif;font-weight:700;letter-spacing:-.035em}.ilo--link-list--links--headline{font-size:18.66px;line-height:24.26px;margin-bottom:.9782761332rem;margin-top:2.1036780625rem}.ilo--link-list--links--item.indented{padding-left:1.7148981779rem}.ilo--link-list--links--item.indented .ilo--link-list--label{display:block;padding-left:1.0718113612rem;position:relative}.ilo--link-list--links--item.indented .ilo--link-list--label:before{background-position:0;background-repeat:no-repeat;background-size:contain;content:"";display:block;height:.6430868167rem;left:0;position:absolute;top:50%;transform:translateY(-50%) rotate(-90deg);transform-origin:center;width:.6430868167rem;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 11'%3E%3Cpath fill='%23B8C4CC' d='M6 10.846L12 0H0l6 10.846z'/%3E%3C/svg%3E")}[dir=rtl] .ilo--link-list--links--item.indented .ilo--link-list--label{padding-right:1.2861736334rem}[dir=rtl] .ilo--link-list--links--item.indented .ilo--link-list--label:before{transform:translateY(-50%) rotate(90deg);left:unset;right:0}.ilo--link-list--links--item.indented .ilo--link-list--link:focus .ilo--link-list--label:before,.ilo--link-list--links--item.indented .ilo--link-list--link:hover .ilo--link-list--label:before,.ilo--link-list--links--item.indented:focus .ilo--link-list--label:before,.ilo--link-list--links--item.indented:hover .ilo--link-list--label:before{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 11'%3E%3Cpath fill='%231E2DBE' d='M6 10.846L12 0H0l6 10.846z'/%3E%3C/svg%3E")}.ilo--link-list--link{background-position:calc(100% - 4px) 50%;background-repeat:no-repeat;background-size:1.2861736334rem 1.2861736334rem;border-bottom:.1071811361rem solid #edf0f2;color:#230050;display:block;font-family:Overpass,Noto Sans,Noto Sans CJK JP,Yu Gothic,Hiragino Sans,TakaoPGothic,PingFang SC,Microsoft YaHei,微软雅黑,sans-serif;font-weight:500;font-size:16px;letter-spacing:normal;line-height:23.36px;padding-top:.857449089rem;padding-bottom:.857449089rem;padding-inline-end:1.7148981779rem;text-decoration:none;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23230050' d='M8.638 19.996l-.988-.988L14.657 12 7.65 4.992l.988-.989 7.505 7.5a.702.702 0 0 1 0 .995l-7.505 7.498z'/%3E%3C/svg%3E");transition-property:color,background-color,border-color;transition-duration:.15s;transition-timing-function:ease-out}.ilo--link-list--link:active,.ilo--link-list--link:visited{color:#230050;transition-property:color;transition-duration:.15s;transition-timing-function:ease-out}.ilo--link-list--link:active{outline:0}.ilo--link-list--link:focus,.ilo--link-list--link:hover{border-bottom:.1071811361rem solid #1e2dbe;background-color:#ebf5fd;color:#1e2dbe;outline:0;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%231E2DBE' d='M8.638 19.996l-.988-.988L14.657 12 7.65 4.992l.988-.989 7.505 7.5a.702.702 0 0 1 0 .995l-7.505 7.498z'/%3E%3C/svg%3E");transition-property:color,background-color,border-color;transition-duration:.15s;transition-timing-function:ease-out}[dir=rtl] .ilo--link-list--link{background-position:.2143622722rem;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23230050' d='M7.9 12.5l-.2-.2c0-.1-.1-.2-.1-.3s0-.2.1-.3c0-.1.1-.2.2-.2L15.4 4l1 1-7 7 7 7-1 1-7.5-7.5z'/%3E%3C/svg%3E")}[dir=rtl] .ilo--link-list--link:focus,[dir=rtl] .ilo--link-list--link:hover{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%231E2DBE' d='M7.9 12.5l-.2-.2c0-.1-.1-.2-.1-.3s0-.2.1-.3c0-.1.1-.2.2-.2L15.4 4l1 1-7 7 7 7-1 1-7.5-7.5z'/%3E%3C/svg%3E")}.ilo--link-list--dark .ilo--link-list--headline,.ilo--link-list--dark .ilo--link-list--links--headline{color:#fff}.ilo--link-list--dark .ilo--link-list--label:before{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 11'%3E%3Cpath fill='%23FFF' d='M6 10.846L12 0H0l6 10.846z'/%3E%3C/svg%3E")}.ilo--link-list--dark .ilo--link-list--link{border-bottom:.1071811361rem solid rgba(237,240,242,.4);background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23FFF' d='M8.638 19.996l-.988-.988L14.657 12 7.65 4.992l.988-.989 7.505 7.5a.702.702 0 0 1 0 .995l-7.505 7.498z'/%3E%3C/svg%3E")}.ilo--link-list--dark .ilo--link-list--link .ilo--link-list--label{color:#fff}.ilo--link-list--dark .ilo--link-list--link:visited .ilo--link-list--label{color:#fff;transition-property:color;transition-duration:.15s;transition-timing-function:ease-out}.ilo--link-list--dark .ilo--link-list--link:active{outline:0}.ilo--link-list--dark .ilo--link-list--link:active .ilo--link-list--label{color:#230050;transition-property:color;transition-duration:.15s;transition-timing-function:ease-out}.ilo--link-list--dark .ilo--link-list--link:focus,.ilo--link-list--dark .ilo--link-list--link:hover{outline:0;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%231E2DBE' d='M8.638 19.996l-.988-.988L14.657 12 7.65 4.992l.988-.989 7.505 7.5a.702.702 0 0 1 0 .995l-7.505 7.498z'/%3E%3C/svg%3E")}.ilo--link-list--dark .ilo--link-list--link:focus .ilo--link-list--label,.ilo--link-list--dark .ilo--link-list--link:hover .ilo--link-list--label{color:#1e2dbe;transition-property:color;transition-duration:.15s;transition-timing-function:ease-out}[dir=rtl] .ilo--link-list--dark .ilo--link-list--link{background-position:.2143622722rem;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23FFF' d='M7.9 12.5l-.2-.2c0-.1-.1-.2-.1-.3s0-.2.1-.3c0-.1.1-.2.2-.2L15.4 4l1 1-7 7 7 7-1 1-7.5-7.5z'/%3E%3C/svg%3E")}[dir=rtl] .ilo--link-list--dark .ilo--link-list--link:focus,[dir=rtl] .ilo--link-list--dark .ilo--link-list--link:hover{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%231E2DBE' d='M7.9 12.5l-.2-.2c0-.1-.1-.2-.1-.3s0-.2.1-.3c0-.1.1-.2.2-.2L15.4 4l1 1-7 7 7 7-1 1-7.5-7.5z'/%3E%3C/svg%3E")}.wingsuit-body .ilo--link-list--dark{background-color:#230050}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
{#
|
|
2
|
+
LINK LIST COMPONENT
|
|
3
|
+
#}
|
|
4
|
+
<div class="ilo--link-list ilo--link-list--{{theme}}" data-loadcomponent="LinkList" data-prefix="ilo">
|
|
5
|
+
{% if headline %}
|
|
6
|
+
<h3 class="ilo--link-list--headline">{{headline}}</h3>
|
|
7
|
+
{% endif %}
|
|
8
|
+
<ul class="ilo--link-list--linkgroups">
|
|
9
|
+
{% for group in linkgroup %}
|
|
10
|
+
<li class="ilo--link-list--linkgroups-item">
|
|
11
|
+
{% if group.headline is not empty %}
|
|
12
|
+
<h4 class="ilo--link-list--links--headline">{{group.headline}}</h4>
|
|
13
|
+
{% endif %}
|
|
14
|
+
<ul class="ilo--link-list--links">
|
|
15
|
+
{% for link in group.links %}
|
|
16
|
+
<li class="ilo--link-list--links--item{% if link.indented == 'true' %} indented{% endif %}">
|
|
17
|
+
<a href="{{link.url}}" class="ilo--link-list--link">
|
|
18
|
+
<span class="ilo--link-list--label">{{link.label}}</span>
|
|
19
|
+
</a>
|
|
20
|
+
</li>
|
|
21
|
+
{% endfor %}
|
|
22
|
+
</ul>
|
|
23
|
+
</li>
|
|
24
|
+
{% endfor %}
|
|
25
|
+
</ul>
|
|
26
|
+
</div>
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
linklist:
|
|
2
|
+
use: "@components/linklist/linklist.twig"
|
|
3
|
+
namespace: Components/Navigation
|
|
4
|
+
label: Link List
|
|
5
|
+
description: The Link List receives a list of urls with labels and an optional prop indicating if this link is at the end of a 'section.'
|
|
6
|
+
fields:
|
|
7
|
+
headline:
|
|
8
|
+
type: string
|
|
9
|
+
label: Headline
|
|
10
|
+
description: Link List's Headline
|
|
11
|
+
preview: Link List Headling
|
|
12
|
+
linkgroup:
|
|
13
|
+
type: object
|
|
14
|
+
label: Link Group
|
|
15
|
+
description: A group of links
|
|
16
|
+
required: true
|
|
17
|
+
preview:
|
|
18
|
+
- headline: Section Headline
|
|
19
|
+
links:
|
|
20
|
+
- label: Link One
|
|
21
|
+
url: "http://www.google.com"
|
|
22
|
+
- label: Link Two
|
|
23
|
+
url: "http://www.google.com"
|
|
24
|
+
- label: Link Three
|
|
25
|
+
url: "http://www.google.com"
|
|
26
|
+
- label: Link Four
|
|
27
|
+
url: "http://www.google.com"
|
|
28
|
+
- label: Link Five Is Slightly Longer
|
|
29
|
+
url: "http://www.google.com"
|
|
30
|
+
- headline: Section 2 (With Indents)
|
|
31
|
+
links:
|
|
32
|
+
- label: Section 2 Link One
|
|
33
|
+
url: "http://www.google.com"
|
|
34
|
+
- indented: "true"
|
|
35
|
+
label: Section 2 Link Two
|
|
36
|
+
url: "http://www.google.com"
|
|
37
|
+
- indented: "true"
|
|
38
|
+
label: Section 2 Link Three
|
|
39
|
+
url: "http://www.google.com"
|
|
40
|
+
- indented: "true"
|
|
41
|
+
label: Section 2 Link Four
|
|
42
|
+
url: "http://www.google.com"
|
|
43
|
+
- label: Section 2 Link Five Is Slightly Longer
|
|
44
|
+
url: "http://www.google.com"
|
|
45
|
+
settings:
|
|
46
|
+
theme:
|
|
47
|
+
type: select
|
|
48
|
+
label: Theme
|
|
49
|
+
description: Is this link list on a light or dark background?
|
|
50
|
+
required: true
|
|
51
|
+
options:
|
|
52
|
+
light: Light
|
|
53
|
+
dark: Dark
|
|
54
|
+
preview: "light"
|
|
55
|
+
visibility: storybook
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@charset "UTF-8";.ilo--list ol{counter-reset:a}.ilo--list ol li{counter-increment:a;display:table}.ilo--list ol li:before{content:counter(a) ".";display:table-cell;text-align:right;padding-inline-end:.4287245445rem}.ilo--list ul li{position:relative;padding-inline-start:1.2861736334rem}.ilo--list ul li:before{content:"";position:absolute;height:.7502679528rem;width:.6430868167rem;top:.3215434084rem;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 11 12.4'%3E%3Cpath fill='%23B8C4CC' d='M10.8 6.4L0 .4v12l10.8-6z'/%3E%3C/svg%3E");background-repeat:no-repeat;left:0;right:0}[dir=rtl] .ilo--list ul li:before{transform:rotate(180deg)}@media screen and (min-width:610px){.ilo--list ul li:before{top:.3751339764rem}}.ilo--list li{font-size:16px;letter-spacing:normal;line-height:23.36px;font-family:Noto Sans,Noto Sans CJK JP,Yu Gothic,Hiragino Sans,TakaoPGothic,PingFang SC,Microsoft YaHei,微软雅黑,sans-serif;margin-bottom:.857449089rem}.ilo--list li b,.ilo--list li strong{font-weight:700;letter-spacing:-.02em}@media screen and (min-width:610px){.ilo--list li{font-size:18.66px;letter-spacing:normal;line-height:27.24px}}.ilo--list--title{font-size:18.66px;letter-spacing:-.035em;line-height:24.26px;margin-bottom:1.2861736334rem;font-family:Overpass,Noto Sans,Noto Sans CJK JP,Yu Gothic,Hiragino Sans,TakaoPGothic,PingFang SC,Microsoft YaHei,微软雅黑,sans-serif;font-weight:700}@media screen and (min-width:610px){.ilo--list--title{font-size:23.32px;letter-spacing:-.035em;line-height:29.15px}}.ilo--list__unstyled ol,.ilo--list__unstyled ul{list-style:none}.ilo--list__unstyled ol li,.ilo--list__unstyled ul li{padding-inline-start:0}.ilo--list__unstyled ol li:before,.ilo--list__unstyled ul li:before{content:none}.ilo--list__horizontal,.ilo--list__horizontal ol,.ilo--list__horizontal ul{display:flex;flex-flow:row;list-style:none;gap:2.1436227224rem}.ilo--list__horizontal li,.ilo--list__horizontal ol li,.ilo--list__horizontal ul li{padding:0}.ilo--list__horizontal li:before,.ilo--list__horizontal ol li:before,.ilo--list__horizontal ul li:before{content:none}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
{# list.twig #}
|
|
2
|
+
|
|
3
|
+
{% if not ordered %}
|
|
4
|
+
{% set ordered = "unstyled" %}
|
|
5
|
+
{% endif %}
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
<div class="ilo--list {% if ordered == 'unstyled' %} ilo--list__unstyled {% endif %} {% if alignment == 'horizontal' %} ilo--list__horizontal {% endif %}">
|
|
9
|
+
{% if title %}
|
|
10
|
+
<h2 class="ilo--list--title">{{ title }}</h2>
|
|
11
|
+
{% endif %}
|
|
12
|
+
{% if ordered == "ordered" %}
|
|
13
|
+
<ol>
|
|
14
|
+
{% for item in items %}
|
|
15
|
+
{% include "@components/list/list-item.twig" with {
|
|
16
|
+
prefix: prefix,
|
|
17
|
+
label: item.label,
|
|
18
|
+
content: item.content,
|
|
19
|
+
id: item.id,
|
|
20
|
+
} only %}
|
|
21
|
+
{% endfor %}
|
|
22
|
+
</ol>
|
|
23
|
+
{% else %}
|
|
24
|
+
<ul>
|
|
25
|
+
{% for item in items %}
|
|
26
|
+
{% include "@components/list/list-item.twig" with {
|
|
27
|
+
prefix: prefix,
|
|
28
|
+
label: item.label,
|
|
29
|
+
content: item.content,
|
|
30
|
+
id: item.id,
|
|
31
|
+
} only %}
|
|
32
|
+
{% endfor %}
|
|
33
|
+
</ul>
|
|
34
|
+
{% endif %}
|
|
35
|
+
</div>
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
list:
|
|
2
|
+
namespace: Components/Content
|
|
3
|
+
use: "@components/list/list.twig"
|
|
4
|
+
label: List
|
|
5
|
+
description: The List component renders a styled list of text items. In addition to the List styles made available in the RichText component, the List component also includes unstyled and horizontally aligned lists.
|
|
6
|
+
fields:
|
|
7
|
+
title:
|
|
8
|
+
type: text
|
|
9
|
+
label: Label
|
|
10
|
+
description: The list item's heading.
|
|
11
|
+
preview: Facts about the ILO
|
|
12
|
+
items:
|
|
13
|
+
type: object
|
|
14
|
+
label: Items
|
|
15
|
+
description: Array of the list items
|
|
16
|
+
required: true
|
|
17
|
+
preview:
|
|
18
|
+
- content: The International Labour Organization (ILO) was founded in 1919 as part of the League of Nations to promote workers' rights, encourage decent employment opportunities, and enhance social protection.
|
|
19
|
+
id: item1
|
|
20
|
+
- content: The ILO aims to promote rights at work, encourage decent job opportunities, enhance social protection, and strengthen dialogue on work-related issues.
|
|
21
|
+
id: item2
|
|
22
|
+
- content: The ILO advocates for social justice and internationally recognized human and labor rights.
|
|
23
|
+
id: item3
|
|
24
|
+
- content: The ILO develops international labor standards in the form of conventions and recommendations to improve working conditions and labor rights.
|
|
25
|
+
id: item4
|
|
26
|
+
- content: The ILO is unique in its tripartite structure that includes representatives from government, employer, and worker organizations.
|
|
27
|
+
id: item5
|
|
28
|
+
- content: The ILO works to eradicate child labor, targeting the worst forms of child labor through conventions and action programs.
|
|
29
|
+
id: item6
|
|
30
|
+
- content: The ILO promotes gender equality and empowers women through targeted policies and programs.
|
|
31
|
+
id: item7
|
|
32
|
+
- content: The ILO’s Decent Work agenda aims to secure fair income, safety at work, social protection, and respect for workers' rights.
|
|
33
|
+
id: item8
|
|
34
|
+
- content: The ILO provides research and data on global employment trends and labor market issues to inform policy development.
|
|
35
|
+
id: item9
|
|
36
|
+
- content: The ILO offers training and education programs to improve occupational skills and competencies.
|
|
37
|
+
id: item10
|
|
38
|
+
- content: The annual International Labor Conference is where ILO members convene to discuss and create labor standards.
|
|
39
|
+
id: item11
|
|
40
|
+
settings:
|
|
41
|
+
ordered:
|
|
42
|
+
type: select
|
|
43
|
+
label: Ordered
|
|
44
|
+
description: The order for the list. `Ordered` uses numbers, `unordered` uses arrow indicators and `unstyled` doesn't have anything but spacing. `unstyled` is the default.
|
|
45
|
+
required: false
|
|
46
|
+
options:
|
|
47
|
+
ordered: Ordered
|
|
48
|
+
unordered: Unordered
|
|
49
|
+
unstyled: Unstyled
|
|
50
|
+
preview: "unstyled"
|
|
51
|
+
alignment:
|
|
52
|
+
type: select
|
|
53
|
+
label: Alignment
|
|
54
|
+
description: Is the list displayed horizontally? Usually used for shorter items inside a list.
|
|
55
|
+
options:
|
|
56
|
+
default: Default
|
|
57
|
+
horizontal: Horizontal
|
|
58
|
+
preview: "default"
|
|
59
|
+
required: false
|
|
60
|
+
visibility: storybook
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
list:
|
|
2
|
+
namespace: Components/Content
|
|
3
|
+
use: "@components/list/list-item.twig"
|
|
4
|
+
label: List Item
|
|
5
|
+
description: A list item.
|
|
6
|
+
fields:
|
|
7
|
+
content:
|
|
8
|
+
type: text
|
|
9
|
+
label: Content
|
|
10
|
+
description: The list item's collapsed content.
|
|
11
|
+
preview:
|
|
12
|
+
faker: lorem.word
|
|
13
|
+
id:
|
|
14
|
+
type: text
|
|
15
|
+
label: ID
|
|
16
|
+
description: The list item's id.
|
|
17
|
+
preview:
|
|
18
|
+
faker: lorem.word
|
|
19
|
+
visibility: storybook
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
!function(e){"function"==typeof define&&define.amd?define(e):e()}((function(){"use strict";function e(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,t||"default");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}function t(t,n){for(var i=0;i<n.length;i++){var r=n[i];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,e(r.key),r)}}var n="itemsloading",i="itemsloaded",r=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.element=t,this.prefix="".concat(this.element.dataset.prefix,"--loading"),this.status="idle",this.init()},(r=[{key:"init",value:function(){return this.setupHandlers().enable(),this}},{key:"setupHandlers",value:function(){return this.LoadingHandler=this.loading.bind(this),this.LoadedHandler=this.loaded.bind(this),this}},{key:"enable",value:function(){var e=this;return document.addEventListener(n,(function(){return e.LoadingHandler})),document.addEventListener(i,(function(){return e.LoadedHandler})),this}},{key:"loading",value:function(){return this.element.classList.remove("".concat(this.prefix,"--idle")),this.element.classList.add("".concat(this.prefix,"--loading")),this}},{key:"loaded",value:function(){return this.element.classList.remove("".concat(this.prefix,"--loading")),this.element.classList.add("".concat(this.prefix,"--loaded")),this.element.querySelector(".".concat(this.prefix,"--copy")).innerHTML=this.element.dataset.loadedmessage,this}}])&&t(e.prototype,r),a&&t(e,a),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,r,a}();Drupal.behaviors.loading={attach:function(){Array.prototype.forEach.call(document.querySelectorAll('[data-loadcomponent="Loading"]'),(function(e){e.dataset.jsProcessed||(new r(e),e.dataset.jsProcessed=!0)}))}}}));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@charset "UTF-8";@keyframes a{to{transform:rotate(1turn)}}.ilo--loading{align-items:center;display:flex;justify-content:center;position:relative}.ilo--loading--large .ilo--loading--copy{width:1px;height:1px;margin:-1px;padding:0;border:0;position:absolute;clip:rect(0 0 0 0);overflow:hidden}.ilo--loading--large.ilo--loading--loading:before{animation:a 1.5s linear infinite;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 107.7 107.7'%3E%3Ccircle cx='53.8' cy='53.7' r='53.9' fill='%23fff'/%3E%3Cpath fill='%23b8c4cc' d='M101.8 53.7c0-10.8-3.6-21.2-10.3-29.7-6.7-8.5-16-14.4-26.5-17s-21.5-1.4-31.3 3.1C23.9 14.7 16 22.4 11.1 32c-4.9 9.6-6.4 20.6-4.3 31.2 2.1 10.6 7.7 20.1 15.9 27.1s18.5 11 29.3 11.5c10.8.4 21.4-2.8 30.1-9.1l-4.7-6.4c-7.3 5.3-16.1 8-25.1 7.6-9-.4-17.6-3.7-24.5-9.6-6.8-5.9-11.5-13.9-13.3-22.7-1.8-8.8-.5-18 3.6-26S28.9 21.2 37 17.4c8.2-3.8 17.4-4.7 26.1-2.6 8.8 2.1 16.5 7.1 22.1 14.2s8.6 15.8 8.6 24.8h8z'/%3E%3Cpath fill='%231e2dbe' d='M97.8 74.9l9.5-17.2h-19l9.5 17.2z'/%3E%3C/svg%3E");height:5.7609860665rem;width:5.7609860665rem}.ilo--loading--large.ilo--loading--loaded:before,.ilo--loading--large.ilo--loading--loading:before{background-position:50%;background-repeat:no-repeat;background-size:contain;content:"";display:block}.ilo--loading--large.ilo--loading--loaded:before{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='97' height='96' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M.237 48c0-26.51 21.49-48 48-48s48 21.49 48 48-21.49 48-48 48-48-21.49-48-48z' fill='%23EDF0F2'/%3E%3Cpath d='M20.237 48c0-15.464 12.536-28 28-28 15.463 0 28 12.536 28 28s-12.536 28-28 28-28-12.536-28-28z' fill='%231E2DBE'/%3E%3Cpath d='M44.037 50.8l-5.6-5.6-4.2 4.2 9.8 9.8 18.2-18.2-4.2-4.2-14 14z' fill='%23fff'/%3E%3C/svg%3E");height:5.1446945338rem;width:5.1446945338rem}.ilo--loading--small .ilo--loading--copy{color:#6d6d6d;font-family:Noto Sans,Noto Sans CJK JP,Yu Gothic,Hiragino Sans,TakaoPGothic,PingFang SC,Microsoft YaHei,微软雅黑,sans-serif;font-weight:400;font-size:14.93px;letter-spacing:-.02em;line-height:20.16px}.ilo--loading--small.ilo--loading--idle .ilo--loading--copy{width:1px;height:1px;margin:-1px;padding:0;border:0;position:absolute;clip:rect(0 0 0 0);overflow:hidden}.ilo--loading--small.ilo--loading--loading:before{animation:a 1.5s linear infinite;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 27.3 27.3'%3E%3Ccircle cx='13.7' cy='13.7' r='13.7' fill='%23fff'/%3E%3Cpath fill='%23b8c4cc' d='M25.7 13.7c0-2.7-.9-5.3-2.6-7.4-1.7-2.1-4-3.6-6.6-4.2-2.6-.6-5.4-.4-7.8.8-2.5 1-4.5 2.9-5.7 5.3-1.2 2.4-1.6 5.1-1.1 7.8.5 2.6 1.9 5 4 6.8 2 1.8 4.6 2.8 7.3 2.9 2.7.1 5.3-.7 7.5-2.3L18.9 21c-1.6 1.2-3.6 1.8-5.6 1.7-2-.1-4-.8-5.5-2.1s-2.6-3.1-3-5.1-.1-4 .8-5.8C6.5 7.8 8 6.3 9.9 5.5c1.8-.8 3.9-1 5.9-.6 2 .5 3.7 1.6 5 3.2 1.3 1.6 1.9 3.6 1.9 5.6h3z'/%3E%3Cpath fill='%231e2dbe' d='M24.2 20.6l3-5.4h-6l3 5.4z'/%3E%3C/svg%3E")}.ilo--loading--small.ilo--loading--loaded:before,.ilo--loading--small.ilo--loading--loading:before{background-position:50%;background-repeat:no-repeat;background-size:contain;content:"";display:block;height:1.2861736334rem;margin-right:.6430868167rem;width:1.2861736334rem}.ilo--loading--small.ilo--loading--loaded:before{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='24' height='24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0 12C0 5.373 5.373 0 12 0s12 5.373 12 12-5.373 12-12 12S0 18.627 0 12z' fill='%231E2DBE'/%3E%3Cpath d='M10.2 13.2l-2.4-2.4L6 12.6l4.2 4.2L18 9l-1.8-1.8-6 6z' fill='%23fff'/%3E%3C/svg%3E")}.ilo--loading.storybook{height:400px;width:100%}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
{#
|
|
2
|
+
LOADING COMPONENT
|
|
3
|
+
#}
|
|
4
|
+
<div class="storybook ilo--loading ilo--loading--{{size}} ilo--loading--{{status}}" role="alert" aria-live="assertive" data-loadcomponent="Loading" data-prefix="ilo">
|
|
5
|
+
{% if message or loadedmessage %}
|
|
6
|
+
<p class="ilo--loading--copy">{% if message and not status == 'loaded' %}{{message}}{% endif %}{% if loadedmessage and status == 'loaded' %}{{loadedmessage}}{% endif %}</p>
|
|
7
|
+
{% endif %}
|
|
8
|
+
</div>
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
loading:
|
|
2
|
+
namespace: Components/Transitions
|
|
3
|
+
use: "@components/loading/loading.twig"
|
|
4
|
+
label: Loading
|
|
5
|
+
description: The Loading component displays a loading state. (See Javascript comments in loading.js for how to use this with vanilla JS).
|
|
6
|
+
fields:
|
|
7
|
+
message:
|
|
8
|
+
type: string
|
|
9
|
+
label: Message
|
|
10
|
+
description: The loading message
|
|
11
|
+
preview: "Submitting"
|
|
12
|
+
required: true
|
|
13
|
+
loadedmessage:
|
|
14
|
+
type: string
|
|
15
|
+
label: LOaded Message
|
|
16
|
+
description: The loaded message
|
|
17
|
+
preview: "Completed"
|
|
18
|
+
required: true
|
|
19
|
+
settings:
|
|
20
|
+
size:
|
|
21
|
+
type: select
|
|
22
|
+
label: Size
|
|
23
|
+
description: The size of the loader
|
|
24
|
+
required: true
|
|
25
|
+
options:
|
|
26
|
+
small: Small
|
|
27
|
+
large: Large
|
|
28
|
+
preview: "large"
|
|
29
|
+
status:
|
|
30
|
+
type: select
|
|
31
|
+
label: Status
|
|
32
|
+
description: The status of the loading content
|
|
33
|
+
required: true
|
|
34
|
+
options:
|
|
35
|
+
idle: Idle
|
|
36
|
+
loading: Loading
|
|
37
|
+
loaded: Loaded
|
|
38
|
+
preview: "loading"
|
|
39
|
+
visibility: storybook
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
{#
|
|
2
|
+
LOCALNAV COMPONENT
|
|
3
|
+
#}
|
|
4
|
+
<header class="ilo--header ilo--header--local" data-loadcomponent="Navigation" data-prefix="ilo">
|
|
5
|
+
<div class="ilo--header--utility-bar ilo--header--utility-bar--local" {% if background %} style="background: {{background}};"{% endif %}>
|
|
6
|
+
<nav class="ilo--nav--local">
|
|
7
|
+
<div class="ilo--nav--local--logo-wrapper">
|
|
8
|
+
<a href="{{siteurl}}" class="ilo--nav--local--logo-link">
|
|
9
|
+
<img src="{{logo.image}}" alt="{{logo.alt}}" class="ilo--nav--local--logo">
|
|
10
|
+
</a>
|
|
11
|
+
</div>
|
|
12
|
+
|
|
13
|
+
<ul class="ilo--nav--local--set">
|
|
14
|
+
{% for item in primarynav.items %}
|
|
15
|
+
<li class="ilo--nav--local--item">
|
|
16
|
+
<a href="{{item.link}}" class="ilo--nav--local--link">
|
|
17
|
+
<span>{{item.label}}</span>
|
|
18
|
+
</a>
|
|
19
|
+
</li>
|
|
20
|
+
{% endfor %}
|
|
21
|
+
</ul>
|
|
22
|
+
</nav>
|
|
23
|
+
<div class="ilo--language-switcher">
|
|
24
|
+
<div class="ilo--language-switcher--wrap">
|
|
25
|
+
{% if mainlink is defined %}
|
|
26
|
+
<span class="ilo--language-switcher--link--wrap">
|
|
27
|
+
<a href="{{mainlink.url}}" class="ilo--language-switcher--link">{{mainlink.label}}</a>
|
|
28
|
+
</span>
|
|
29
|
+
{% endif %}
|
|
30
|
+
{% if languagecontextmenu.links is not empty %}
|
|
31
|
+
<button class="ilo--language-switcher--button" type="button">
|
|
32
|
+
{{languagelabel}}
|
|
33
|
+
</button>
|
|
34
|
+
{% include '@components/contextmenu/contextmenu.twig' with {
|
|
35
|
+
links: languagecontextmenu.links,
|
|
36
|
+
prefix: prefix
|
|
37
|
+
}
|
|
38
|
+
%}
|
|
39
|
+
{% endif %}
|
|
40
|
+
</div> <!-- /.ilo--language-switcher--wrap -->
|
|
41
|
+
</div> <!-- /.ilo--language-switcher -->
|
|
42
|
+
<button class="ilo--header--menu">Menu</button>
|
|
43
|
+
</div> <!-- /.ilo--header--utility-bar -->
|
|
44
|
+
|
|
45
|
+
<div class="ilo--header--navigation">
|
|
46
|
+
<div class="ilo--header--inner">
|
|
47
|
+
<div class="ilo--mobile--nav">
|
|
48
|
+
<div class="ilo--mobile--nav--logo">
|
|
49
|
+
<a href="{{siteurl}}" class="ilo--header--logo-link">
|
|
50
|
+
<img class="ilo--header--logo" src="{{mobilelogo.image}}" alt="{{mobilelogo.alt}}">
|
|
51
|
+
</a>
|
|
52
|
+
<button class="ilo--header--menu--close">{{menucloselabel}}</button>
|
|
53
|
+
</div> <!-- /.ilo--mobile--logo -->
|
|
54
|
+
{% if languagecontextmenu.links is not empty %}
|
|
55
|
+
<div class="ilo--mobile--nav--language--switcher">
|
|
56
|
+
<button class="ilo--mobile--nav--language--switcher--button" type="button">{{languagelabel}}</button>
|
|
57
|
+
</div> <!-- /.ilo--mobile--nav--language--switcher -->
|
|
58
|
+
<div class="ilo--mobile--nav--language--select">
|
|
59
|
+
<div class="ilo--header--inner">
|
|
60
|
+
<div class="ilo--mobile--subnav--menu">
|
|
61
|
+
<button class="ilo--mobile--subnav--back" type="button">{{subnav.mobilebacklabel}}</button>
|
|
62
|
+
<button class="ilo--header--menu--close">{{subnav.mobilecloselabel}}</button>
|
|
63
|
+
<h6 class="ilo--mobile--subnav--label">{{languagelabel}}</h6>
|
|
64
|
+
</div> <!-- /ilo--mobile--subnav--menu -->
|
|
65
|
+
<ul class="ilo--nav--set">
|
|
66
|
+
{% for item in languagecontextmenu.links %}
|
|
67
|
+
<li class="ilo--nav--items">
|
|
68
|
+
<a href="{{item.url}}" class="ilo--nav--link ilo--nav--language">{{item.label}}</a>
|
|
69
|
+
</li>
|
|
70
|
+
{% endfor %}
|
|
71
|
+
</ul>
|
|
72
|
+
</div>
|
|
73
|
+
</div>
|
|
74
|
+
{% endif %}
|
|
75
|
+
</div> <!-- /.ilo--mobile--nav -->
|
|
76
|
+
<nav class="ilo--nav" aria-labelledby="primary-navigation">
|
|
77
|
+
<h2 class="ilo--nav--label" id="primary-navigation">{{primarynav.navlabel}}</h2>
|
|
78
|
+
<ul class="ilo--nav--set">
|
|
79
|
+
{% for item in primarynav.items %}
|
|
80
|
+
<li class="ilo--nav--items">
|
|
81
|
+
<a href="{{item.link}}" class="ilo--nav--link">{{item.label}}</a>
|
|
82
|
+
</li>
|
|
83
|
+
{% endfor %}
|
|
84
|
+
</ul>
|
|
85
|
+
</nav>
|
|
86
|
+
</header>
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
localnav:
|
|
2
|
+
namespace: Components/Navigation
|
|
3
|
+
use: "@components/localnav/localnav.twig"
|
|
4
|
+
label: Local nav
|
|
5
|
+
description: The Local nav component
|
|
6
|
+
fields:
|
|
7
|
+
background:
|
|
8
|
+
type: string
|
|
9
|
+
label: Background
|
|
10
|
+
description: Override color for the background
|
|
11
|
+
preview: "#1E2DBE"
|
|
12
|
+
logo:
|
|
13
|
+
type: object
|
|
14
|
+
label: Logo
|
|
15
|
+
description: Logo for the nav
|
|
16
|
+
required: true
|
|
17
|
+
preview:
|
|
18
|
+
image: "/brand-assets/logo_en_horizontal_white.svg"
|
|
19
|
+
alt: Logo
|
|
20
|
+
siteurl:
|
|
21
|
+
type: string
|
|
22
|
+
label: Site url
|
|
23
|
+
description: home url for the website
|
|
24
|
+
required: true
|
|
25
|
+
preview: "https://www.ilo.org/"
|
|
26
|
+
tagline:
|
|
27
|
+
type: object
|
|
28
|
+
label: Site tagline
|
|
29
|
+
description: Tagline for the site
|
|
30
|
+
preview:
|
|
31
|
+
tag: Advancing social justice, promoting decent work
|
|
32
|
+
small: ILO is a specialized agency of the United Nations
|
|
33
|
+
menulabel:
|
|
34
|
+
type: string
|
|
35
|
+
label: Menu Label
|
|
36
|
+
description: Label for the menu
|
|
37
|
+
preview: Menu
|
|
38
|
+
menucloselabel:
|
|
39
|
+
type: string
|
|
40
|
+
label: Menu Close Label
|
|
41
|
+
description: Close Label for the menu
|
|
42
|
+
preview: Close
|
|
43
|
+
primarynav:
|
|
44
|
+
type: object
|
|
45
|
+
label: Primary Local nav
|
|
46
|
+
description: Local nav for the primary menu
|
|
47
|
+
preview:
|
|
48
|
+
navlabel: Primary Local nav
|
|
49
|
+
mobilecloselabel: Close
|
|
50
|
+
items:
|
|
51
|
+
- link: "https://www.ilo.org"
|
|
52
|
+
label: Menu Item 1
|
|
53
|
+
- link: "https://www.ilo.org"
|
|
54
|
+
label: Menu Item 2
|
|
55
|
+
- link: "https://www.ilo.org"
|
|
56
|
+
label: Menu Item 3
|
|
57
|
+
- link: "https://www.ilo.org"
|
|
58
|
+
label: Menu Item 4
|
|
59
|
+
mainlink:
|
|
60
|
+
type: object
|
|
61
|
+
label: Main link object
|
|
62
|
+
description: Link object for back to main site link
|
|
63
|
+
preview:
|
|
64
|
+
url: "https://www.ilo.org/"
|
|
65
|
+
label: "Go to main website"
|
|
66
|
+
languagelabel:
|
|
67
|
+
type: string
|
|
68
|
+
label: Language Label
|
|
69
|
+
description: Label for the language switcher
|
|
70
|
+
preview: English
|
|
71
|
+
languagecontextmenu:
|
|
72
|
+
type: object
|
|
73
|
+
label: Language Context Menu
|
|
74
|
+
description: The Language Context Menu receives a list of urls with labels
|
|
75
|
+
preview:
|
|
76
|
+
links:
|
|
77
|
+
- label: Link One
|
|
78
|
+
url: "http://www.google.com"
|
|
79
|
+
- label: Link Two
|
|
80
|
+
url: "http://www.google.com"
|
|
81
|
+
- endsection: "true"
|
|
82
|
+
label: Link Three Ends A Section
|
|
83
|
+
url: "http://www.google.com"
|
|
84
|
+
- label: Link Four
|
|
85
|
+
url: "http://www.google.com"
|
|
86
|
+
- label: Link Five Is Slightly Longer
|
|
87
|
+
url: "http://www.google.com"
|
|
88
|
+
visibility: storybook
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@charset "UTF-8";.ilo--logo--visibility--hidden{visibility:hidden}.ilo--logo--size--fluid{width:100%;height:auto}.ilo--logo--theme--light{--logo-theme-color:#1e2dbe}.ilo--logo--theme--dark{--logo-theme-color:#fff}.ilo--logo--link{all:unset;cursor:pointer}.ilo--logo--image{height:100%;width:100%}.ilo--logo--sub-brand{--lockup-height:calc(var(--logo-image-height) * 0.703);--lockup-bottom-offset:calc(var(--lockup-height) * 0.05);color:var(--logo-theme-color);font-size:var(--logo-font-size);line-height:var(--logo-font-size);font-family:Overpass,Noto Sans,Noto Sans CJK JP,Yu Gothic,Hiragino Sans,TakaoPGothic,PingFang SC,Microsoft YaHei,微软雅黑,sans-serif;font-weight:700;display:inline-flex;justify-content:flex-start;align-items:center}.ilo--logo--sub-brand--image{height:100%;width:50%}.ilo--logo--sub-brand--lock-up{position:relative;display:flex;height:var(--lockup-height);flex-flow:row nowrap;align-items:center;justify-content:flex-start;width:50%;bottom:var(--lockup-bottom-offset)}.ilo--logo--sub-brand--lock-up--separator{padding:0 calc(var(--logo-image-height) * .25);height:100%;display:inline-block;line-height:0;overflow-y:hidden}.ilo--logo--sub-brand--lock-up--separator:before{content:"";position:relative;display:inline-block;height:100%;border-right:calc(var(--logo-image-height) * .033) solid var(--logo-theme-color);width:0}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.ilo--logo-grid--logos{display:flex;flex-flow:row wrap;grid-gap:.857449089rem}.ilo--logo-grid--link{text-decoration:none;transition:background-color .2s ease-in-out}.ilo--logo-grid__theme__dark .ilo--logo-grid--link:hover,.ilo--logo-grid__theme__light .ilo--logo-grid--link:hover{background-color:#ebf5fd}.ilo--logo-grid--item{display:flex;align-items:center;justify-content:center;height:7.18113612rem;flex:100%}@media screen and (min-width:414px){.ilo--logo-grid--item{flex:0 0 12.7545551983rem}}.ilo--logo-grid__theme__light .ilo--logo-grid--item{background-color:#edf0f2}.ilo--logo-grid__theme__dark .ilo--logo-grid--item{background-color:#fff}.ilo--logo-grid--item img{width:auto;height:auto;max-width:8.038585209rem;max-height:2.679528403rem}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
<div class="ilo--logo-grid ilo--logo-grid__theme__{{ theme }}">
|
|
2
|
+
<div class="ilo--logo-grid--logos">
|
|
3
|
+
{% for logo in logos %}
|
|
4
|
+
{% if logo.url %}
|
|
5
|
+
<a href="{{ logo.url }}" class="ilo--logo-grid--item ilo--logo-grid--link">
|
|
6
|
+
{% else %}
|
|
7
|
+
<div class="ilo--logo-grid--item">
|
|
8
|
+
{% endif %}
|
|
9
|
+
<img src="{{ logo.src }}" alt="{{ logo.label }}" class="ilo--logo-grid--logo__image">
|
|
10
|
+
{% if logo.url %}
|
|
11
|
+
</a>
|
|
12
|
+
{% else %}
|
|
13
|
+
</div>
|
|
14
|
+
{% endif %}
|
|
15
|
+
{% endfor %}
|
|
16
|
+
</div>
|
|
17
|
+
</div>
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
logogrid:
|
|
2
|
+
namespace: Components/Brand
|
|
3
|
+
use: "@components/logogrid/logogrid.twig"
|
|
4
|
+
label: Logo Grid
|
|
5
|
+
description: The Logo Grid component renders a series of logos representing a group of organizations. It can be shown on a light or dark background.
|
|
6
|
+
settings:
|
|
7
|
+
theme:
|
|
8
|
+
type: select
|
|
9
|
+
label: Theme
|
|
10
|
+
description: The theme of the component
|
|
11
|
+
default: light
|
|
12
|
+
options:
|
|
13
|
+
light: Light
|
|
14
|
+
dark: Dark
|
|
15
|
+
preview: "light"
|
|
16
|
+
fields:
|
|
17
|
+
logos:
|
|
18
|
+
type: object
|
|
19
|
+
label: Logos
|
|
20
|
+
description: Logos to display
|
|
21
|
+
required: true
|
|
22
|
+
preview:
|
|
23
|
+
- label: "International Labour Organization"
|
|
24
|
+
src: "/images/logo_en_horizontal_blue.svg"
|
|
25
|
+
url: "https://www.ilo.org/"
|
|
26
|
+
|
|
27
|
+
- label: "Food and Agriculture Organization"
|
|
28
|
+
src: "/images/fao-logo.svg"
|
|
29
|
+
url: "https://www.fao.org"
|
|
30
|
+
|
|
31
|
+
- label: "World Health Organization"
|
|
32
|
+
src: "/images/who-logo.svg"
|
|
33
|
+
url: "https://www.who.int/"
|
|
34
|
+
|
|
35
|
+
- label: "World Food Programme"
|
|
36
|
+
src: "/images/wfp-logo.svg"
|
|
37
|
+
url: "https://www.wfp.org/"
|
|
38
|
+
|
|
39
|
+
- label: "UNICEF"
|
|
40
|
+
src: "/images/unicef-logo.png"
|
|
41
|
+
url: "https://www.unicef.org/"
|
|
42
|
+
|
|
43
|
+
- label: "UN Refugees"
|
|
44
|
+
src: "/images/unhcr-logo.svg"
|
|
45
|
+
url: "https://www.unhcr.org/"
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
!function(e){"function"==typeof define&&define.amd?define(e):e()}((function(){"use strict";function e(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,t||"default");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}function t(t,n){for(var i=0;i<n.length;i++){var r=n[i];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,e(r.key),r)}}var n="click",i="keydown",r=function(){return e=function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.element=t,this.init()},(r=[{key:"init",value:function(){return this.cacheDomReferences().setupHandlers().enable(),this}},{key:"cacheDomReferences",value:function(){return this.OpenButton=this.element.querySelector(".modal--open"),this.CloseButton=this.element.querySelector(".modal--close"),this}},{key:"setupHandlers",value:function(){return this.OpenButtonHandler=this.openButtonClick.bind(this),this.CloseHandler=this.closeButtonClick.bind(this),this.KeyPressHandler=this.keyPress.bind(this),this}},{key:"enable",value:function(){var e=this;return this.OpenButton.addEventListener(n,(function(){return e.OpenButtonHandler()})),this.CloseButton.addEventListener(n,(function(){return e.CloseHandler()})),this}},{key:"openButtonClick",value:function(){var e=this;return this.element.classList.add("show"),setTimeout((function(){e.element.classList.add("fadein")}),125),window.addEventListener(i,(function(t){return e.KeyPressHandler(t)})),this}},{key:"closeButtonClick",value:function(){var e=this;return this.element.classList.remove("fadein"),setTimeout((function(){e.element.classList.remove("show")}),125),window.removeEventListener(i,(function(t){return e.KeyPressHandler(t)})),this}},{key:"keyPress",value:function(e){return"Escape"===e.key&&this.closeButtonClick(),this}}])&&t(e.prototype,r),o&&t(e,o),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,r,o}();Drupal.behaviors.modal={attach:function(){Array.prototype.forEach.call(document.querySelectorAll('[data-loadcomponent="Modal"]'),(function(e){e.dataset.jsProcessed||(new r(e),e.dataset.jsProcessed=!0)}))}}}));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.ilo--modal--wrapper{display:none}.ilo--modal--wrapper>*{opacity:0}.ilo--modal.show .ilo--modal--wrapper{display:block;height:100vh;left:0;position:fixed;top:0;width:100vw;z-index:10001}.ilo--modal.show.fadein .ilo--modal--wrapper>*{opacity:1;transition-delay:125ms;transition-property:opacity;transition-duration:.15s;transition-timing-function:ease-out}.ilo--modal--background{background-color:rgba(0,0,0,.85);height:100%;left:0;position:absolute;top:0;width:100%;z-index:10002}.ilo--modal--contents{background-color:#fff;left:0;position:absolute;margin:0 4.2%;max-height:96%;overflow:scroll;top:50%;transform:translateY(-50%);width:91.4%;z-index:10003}.ilo--modal .modal--close{height:2.1436227224rem;right:0;position:absolute;top:0;width:2.1436227224rem;z-index:10004}.ilo--modal .modal--close .ilo--icon{left:.1607717042rem;top:.1607717042rem}@media screen and (min-width:610px){.ilo--modal--contents{margin:0 23.2%;width:53.58%}}@media screen and (min-width:1024px){.ilo--modal--contents{margin:0 18.05%;width:63.888%}}.ilo--modal.storybook{height:400px;width:100%}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
{#
|
|
2
|
+
MODAL COMPONENT
|
|
3
|
+
|
|
4
|
+
The modal calls another Twig into it, and therefore passes `modaldata` into it. `modaldata` should contain the fields for the component in question, just as if the component were being used anywhere else.
|
|
5
|
+
#}
|
|
6
|
+
|
|
7
|
+
{% if component != 'modal' %}
|
|
8
|
+
<div class="ilo--modal" data-loadcomponent="Modal" data-prefix="ilo">
|
|
9
|
+
{% include '@components/button/button.twig' with openbutton %}
|
|
10
|
+
<div class="ilo--modal--wrapper" {% if modalLabel %} aria-label="{{modalLabel}}" {% endif %} aria-modal="true" role="alertdialog">
|
|
11
|
+
<div class="ilo--modal--background" role="presentation"></div>
|
|
12
|
+
<div class="ilo--modal--contents">
|
|
13
|
+
{% block modal_content %}
|
|
14
|
+
{% include '@components/' ~ component ~ '/' ~ component ~ '.twig' with modaldata %}
|
|
15
|
+
{% endblock %}
|
|
16
|
+
{% include '@components/button/button.twig' with closebutton %}
|
|
17
|
+
</div>
|
|
18
|
+
</div>
|
|
19
|
+
</div>
|
|
20
|
+
{% endif %}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
modal:
|
|
2
|
+
use: "@components/modal/modal.twig"
|
|
3
|
+
namespace: Components/Feedback
|
|
4
|
+
label: Modal
|
|
5
|
+
description: The Modal displays a div containing a button which is visible on page load. On click of this button, a modal dialog is opened which displays a semitransparent fixed-position background and the contents of the chosen component.
|
|
6
|
+
fields:
|
|
7
|
+
closebutton:
|
|
8
|
+
type: object
|
|
9
|
+
label: Closee Button
|
|
10
|
+
description: Label and settings for the "close" button
|
|
11
|
+
preview:
|
|
12
|
+
size: "medium"
|
|
13
|
+
type: "tertiary"
|
|
14
|
+
label: "Close Button"
|
|
15
|
+
icon: close
|
|
16
|
+
iconPos: center
|
|
17
|
+
icononly: true
|
|
18
|
+
className: "modal--close"
|
|
19
|
+
required: true
|
|
20
|
+
component:
|
|
21
|
+
type: string
|
|
22
|
+
label: Component
|
|
23
|
+
description: The component to add to this modal
|
|
24
|
+
preview: "image"
|
|
25
|
+
required: true
|
|
26
|
+
modaldata:
|
|
27
|
+
type: object
|
|
28
|
+
label: Modal Data
|
|
29
|
+
description: The fields needed to populate the component being displayed by the modal
|
|
30
|
+
preview:
|
|
31
|
+
alt: "My alt text"
|
|
32
|
+
caption: "my image caption"
|
|
33
|
+
credit: "Photo: copyright 2022 Person S. Name"
|
|
34
|
+
url:
|
|
35
|
+
- breakpoint: 0
|
|
36
|
+
src: "https://place-hold.it/400x300?text=SmallBreakpointImage"
|
|
37
|
+
- breakpoint: 800
|
|
38
|
+
src: "https://place-hold.it/800x600?text=MediumBreakpointImage"
|
|
39
|
+
- breakpoint: 1200
|
|
40
|
+
src: "https://place-hold.it/1200x900?text=LargeBreakpointImage"
|
|
41
|
+
- breakpoint: 1440
|
|
42
|
+
src: "https://place-hold.it/1600x1200?text=LargestBreakpointImage"
|
|
43
|
+
required: true
|
|
44
|
+
openbutton:
|
|
45
|
+
type: object
|
|
46
|
+
label: Open Button
|
|
47
|
+
description: The label and settings for the button that will open the modal
|
|
48
|
+
preview:
|
|
49
|
+
size: "large"
|
|
50
|
+
type: "primary"
|
|
51
|
+
label: "Open Button"
|
|
52
|
+
className: "modal--open"
|
|
53
|
+
opensmodal: true
|
|
54
|
+
required: true
|
|
55
|
+
modalLabel:
|
|
56
|
+
type: string
|
|
57
|
+
label: Modal Label
|
|
58
|
+
description: A modal label added to aria-label attribute to improve accessibility
|
|
59
|
+
preview: "modal"
|
|
60
|
+
required: false
|
|
61
|
+
visibility: storybook
|