|
1 | 1 | <template>
|
2 | 2 | <footer class="footer">
|
3 | 3 | <section class="sitemap">
|
4 |
| - <section class="sitemap-section"> |
5 |
| - <h5>Docs</h5> |
| 4 | + <section v-for="sitemapConfig in sitemap" class="sitemap-section" :key="sitemapConfig.title"> |
| 5 | + <h5>{{ sitemapConfig.title }}</h5> |
6 | 6 | <ul>
|
7 |
| - <li><a href="https://docs.appcelerator.com/" target="_blank">Alloy</a></li> |
8 |
| - <li><a href="https://docs.appcelerator.com/" target="_blank">Hyperloop</a></li> |
9 |
| - </ul> |
10 |
| - </section> |
11 |
| - <section class="sitemap-section"> |
12 |
| - <h5>Community</h5> |
13 |
| - <ul> |
14 |
| - <li><a href="">Slack</a></li> |
15 |
| - </ul> |
16 |
| - </section> |
17 |
| - <section class="sitemap-section"> |
18 |
| - <h5>Social</h5> |
19 |
| - <ul> |
20 |
| - <li><a href="https://github.com/appcelerator" target="_blank">Github</a></li> |
21 |
| - <li><a href="https://twitter.com/appcelerator" target="_blank">Twitter</a></li> |
22 |
| - <li><a href="http://www.linkedin.com/company/200115" target="_blank">LinkedIn</a></li> |
| 7 | + <li v-for="link in sitemapConfig.links" :key="link.text"><a :href="link.link" :target="/^https?:\/\//.test(link.link) ? '_blank' : '_self'">{{ link.text }}</a></li> |
23 | 8 | </ul>
|
24 | 9 | </section>
|
25 | 10 | </section>
|
26 |
| - <a href="https://appcelerator.com" target="_blank"> |
27 |
| - <img :src="$withBase('/images/axway-appcelerator-logo.png')"/> |
| 11 | + <a v-if="logo" :href="logoLink" target="_blank"> |
| 12 | + <img :src="$withBase(logo)"/> |
28 | 13 | </a>
|
29 | 14 | <section class="copyright">
|
30 |
| - Copyright © 2018-present Axway Appcelerator |
| 15 | + {{ copyright }} |
31 | 16 | </section>
|
32 | 17 | </footer>
|
33 | 18 | </template>
|
34 | 19 |
|
| 20 | +<script> |
| 21 | +export default { |
| 22 | + computed: { |
| 23 | + copyright() { |
| 24 | + const { themeConfig } = this.$site; |
| 25 | + return themeConfig && themeConfig.footerCopyright |
| 26 | + }, |
| 27 | + logo() { |
| 28 | + const { themeConfig } = this.$site; |
| 29 | + return themeConfig && themeConfig.footerLogo |
| 30 | + }, |
| 31 | + logoLink() { |
| 32 | + const { themeConfig } = this.$site; |
| 33 | + return themeConfig && themeConfig.footerLogoLink || '/' |
| 34 | + }, |
| 35 | + sitemap() { |
| 36 | + const { themeConfig } = this.$site; |
| 37 | + const sitemap = themeConfig.footerSitemap || [] |
| 38 | + return Object.keys(sitemap).map(sitemapColumnTitle => { |
| 39 | + const sitemapColumnConfig = sitemap[sitemapColumnTitle] |
| 40 | + return { |
| 41 | + title: sitemapColumnTitle, |
| 42 | + links: sitemapColumnConfig |
| 43 | + } |
| 44 | + }) |
| 45 | + } |
| 46 | + } |
| 47 | +} |
| 48 | +</script> |
| 49 | + |
| 50 | + |
35 | 51 | <style lang="stylus">
|
36 | 52 | .footer
|
37 | 53 | background #231f20
|
|
0 commit comments