File tree Expand file tree Collapse file tree 7 files changed +103
-11
lines changed
packages/docs/.vuepress/theme-coreui/src/client Expand file tree Collapse file tree 7 files changed +103
-11
lines changed Original file line number Diff line number Diff line change 1+ <script >
2+ import {h } from ' vue' ;
3+ export default {
4+ props: {},
5+ watch: {
6+ ' $route' (to, from) {
7+ if (
8+ to .path !== from .path
9+ // Only reload if the ad has been loaded
10+ // otherwise it's possible that the script is appended but
11+ // the ads are not loaded yet. This would result in duplicated ads.
12+ && this .$el .querySelector (' #carbonads' )
13+ ) {
14+ this .$el .innerHTML = ' ' ;
15+ this .load ();
16+ }
17+ },
18+ },
19+ mounted () {
20+ this .load ();
21+ },
22+ methods: {
23+ load () {
24+ const s = document .createElement (' script' );
25+ s .id = ' _carbonads_js' ;
26+ s .src = ` //cdn.carbonads.com/carbon.js?serve=CEAICKJY&placement=coreuiio` ;
27+ this .$el .appendChild (s);
28+ },
29+ },
30+ render () {
31+ return h (' div' );
32+ },
33+ };
34+ </script >
Original file line number Diff line number Diff line change 11<template >
2- <CAlert color =" light" class =" d-flex align-items-baseline justify-content-center rounded-0 border-bottom mb-0" >
3- <span class =" me-3" >
4- If you like this project and want to help us, please give us a star ⭐️ on Github. ➡️
5- </span >
6- <CButton color =" dark" component =" a" href =" https://github.com/coreui/coreui-vue" size =" sm" target =" _blank" variant =" outline" ><CIcon icon =" cib-github" /> Star</CButton >
7- <span class =" ms-3" >🙏</span >
8- </CAlert >
92 <CHeader class =" mb-5 elevation-0 border-bottom" position =" sticky" >
103 <CHeaderToggler class =" ms-md-3" @click =" $emit('toggle-sidebar')" >
114 <CIcon icon =" cil-menu" size =" lg" />
Original file line number Diff line number Diff line change 33 <div class =" content" >
44 <h1 >{{ title }}</h1 >
55 <p class =" docs-lead fs-4 fw-light" >{{ description }}</p >
6- <div data-ea-publisher = " coreui-io " data-ea-type = " image " ></ div >
6+ <Ads / >
77 <Content />
88 </div >
99 </div >
@@ -14,8 +14,13 @@ import { defineComponent } from 'vue'
1414import { usePageFrontmatter } from ' @vuepress/client'
1515import type { DefaultThemeNormalPageFrontmatter } from ' ../../shared'
1616
17+ import Ads from ' ./Ads.vue'
18+
1719export default defineComponent ({
1820 name: ' Page' ,
21+ components: {
22+ Ads ,
23+ },
1924 setup() {
2025 const frontmatter = usePageFrontmatter <DefaultThemeNormalPageFrontmatter >()
2126 const title = frontmatter .value .title
Original file line number Diff line number Diff line change 55 @touchstart =" onTouchStart"
66 @touchend =" onTouchEnd"
77 >
8- <Sidebar :visible =" isSidebarOpen" @visible-change =" (event) => isSidebarOpen = event" />
8+ <Sidebar :visible =" isSidebarOpen" @visible-change =" (event) => ( isSidebarOpen = event) " />
99 <div class =" wrapper d-flex flex-column min-vh-100" >
10- <Header @toggle-sidebar =" toggleSidebar(!isSidebarOpen)" />
10+ <Header @toggle-sidebar =" toggleSidebar(!isSidebarOpen)" />
1111 <div class =" body flex-grow-1 px-3" >
1212 <CContainer lg >
1313 <Home v-if =" frontmatter.home" />
2020 >
2121 <CRow >
2222 <CCol :lg =" 9" >
23+ <div
24+ class =" bg-info bg-opacity-10 border-start border-start-5 border-start-info p-4 pb-3 mb-5"
25+ >
26+ <h3 class =" mb-4" >Support CoreUI Development</h3 >
27+ <p >
28+ CoreUI is an MIT-licensed open source project and is completely free to use.
29+ However, the amount of effort needed to maintain and develop new features for
30+ the project is not sustainable without proper financial backing.
31+ </p >
32+ <p >You can support our Open Source software development in the following ways:</p >
33+ <ul >
34+ <li >
35+ Buy the <a href =" https://coreui.io/pricing/?support=vue" >CoreUI PRO</a >,
36+ and get access to PRO components, and dedicated support.
37+ </li >
38+ <li >
39+ <a href =" https://opencollective.com/coreui" target =" _blank"
40+ >Became a sponsor</a
41+ >, and get your logo on BACKERS.md/README.md files or each site of this
42+ documentation
43+ </li >
44+ <li >
45+ Give us a star ⭐️ on
46+ <a href =" https://github.com/coreui/coreui-vue" target =" _blank" >Github</a >.
47+ </li >
48+ </ul >
49+ </div >
2350 <Page :key =" page.path" >
2451 <template #top >
2552 <slot name =" page-top" />
Original file line number Diff line number Diff line change 1+ #carbonads {
2+ position : static ;
3+ display : block ;
4+ max-width : 400px ;
5+ padding : 15px 15px 15px 160px ;
6+ margin : 2rem 0 ;
7+ overflow : hidden ;
8+ @include font-size (.8125rem );
9+ line-height : 1.4 ;
10+ text-align : left ;
11+ background-color : $gray-100 ;
12+
13+ a {
14+ color : $gray-800 ;
15+ text-decoration : none ;
16+ }
17+
18+ @include media-breakpoint-up (sm) {
19+ @include border-radius (.5rem );
20+ }
21+ }
22+
23+ .carbon-img {
24+ float : left ;
25+ margin-left : -145px ;
26+ }
27+
28+ .carbon-poweredby {
29+ display : block ;
30+ margin-top : .75rem ;
31+ color : $gray-700 !important ;
32+ }
Original file line number Diff line number Diff line change 1- .docs-sidebar {
1+ .sidebar. docs-sidebar {
22 --cui-sidebar-bg : #f0f4f7 ;
33 --cui-sidebar-brand-bg : transparent ;
44 --cui-sidebar-brand-color : rgba (44 ,56 ,74 ,0.87 );
Original file line number Diff line number Diff line change 11@import ' @coreui/coreui/scss/coreui.scss' ;
22
3+ @import ' ads' ;
34@import ' anchor' ;
45@import ' demo' ;
56@import ' footer' ;
You can’t perform that action at this time.
0 commit comments