Skip to content
This repository was archived by the owner on Oct 1, 2022. It is now read-only.

Commit 7cfa5d4

Browse files
authored
Merge pull request #196 from pulse-framework/develop
Merge Develop into master
2 parents 7556c1b + da99f1b commit 7cfa5d4

File tree

113 files changed

+16751
-853
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

113 files changed

+16751
-853
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ build/Release
4444
node_modules/
4545
jspm_packages/
4646

47-
# Typescript v1 declaration files
47+
# TypeScript v1 declaration files
4848
typings/
4949

5050
# Optional npm cache directory

deploy.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
y#!/usr/bin/env sh
1+
#!/usr/bin/env sh
22

33
# abort on errors
44
set -e
55

66
# build
7-
yern docs:build
7+
yarn docs:build
88

99
# navigate into the build output directory
1010
cd docs/.vuepress/dist

docs/.vuepress/config.js

Lines changed: 40 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module.exports = {
2-
title: 'Pulse Framework',
3-
description: 'Global state and logic framework for reactive JavaScript applications.',
2+
title: 'Pulse',
3+
description: 'A global state and logic framework for reactive JavaScript & TypeScript applications.',
44
dest: 'dist',
55
serviceWorker: true,
66
base: '/',
@@ -9,8 +9,8 @@ module.exports = {
99
logo: '/logo.svg',
1010
nav: [
1111
{ text: 'Home', link: '/' },
12-
{ text: 'Documentation', link: '/v3/introduction/what-is-pulse' },
13-
{ text: 'Changelog', link: '/v3/introduction/changelog' }
12+
{ text: 'Documentation', link: '/v4/introduction/what-is-pulse' },
13+
{ text: 'Changelog', link: '/v4/introduction/changelog' }
1414
],
1515
lastUpdated: 'Last Updated',
1616
// Assumes GitHub. Can also be a full GitLab url.
@@ -149,6 +149,42 @@ module.exports = {
149149
collapsable: false,
150150
children: ['resources/snippets', 'getting-started/style-guide', 'resources/ideas']
151151
}
152+
],
153+
'/v4/': [
154+
{
155+
title: 'Introduction',
156+
collapsable: false,
157+
children: ['introduction/what-is-pulse', 'introduction/changelog']
158+
},
159+
{
160+
title: 'Getting Started',
161+
collapsable: false,
162+
children: [
163+
'getting-started/concepts',
164+
'getting-started/setup-with-react',
165+
'getting-started/setup-with-vue',
166+
'getting-started/setup-with-next'
167+
]
168+
},
169+
{
170+
title: 'Documentation',
171+
collapsable: false,
172+
children: [
173+
'docs/state',
174+
'docs/collections',
175+
'docs/actions',
176+
// 'docs/controllers',
177+
'docs/core',
178+
'docs/route',
179+
'docs/persisting-data',
180+
'docs/events'
181+
]
182+
},
183+
{
184+
title: 'Resources',
185+
collapsable: false,
186+
children: ['resources/snippets', 'getting-started/style-guide', 'resources/ideas']
187+
}
152188
]
153189
}
154190
},

docs/.vuepress/styles/index.styl

Lines changed: 28 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,22 @@
11
$pulseRed = #EF425A;
2-
$pulseRedLighter = #ff8c9e;
2+
$pulseRedLighter = #FF6292;
33
$pulseCodeBackground = #282e3f;
44
$pulseGrey = #7e9ab3;
55
$pulseFaint = #526577;
6-
$pulseGreen = #28EBB0;
6+
$pulseGreen = #00FFB2;
77
$pulseYellow = #FFD696;
88
$pulseWhite = #F7F8F8;
99
$pulseLightBlue = #B6DCFF;
1010

11-
table code
12-
line-height: 2em !important;
11+
table
12+
tr, td, th
13+
border-color: $pulseGrey;
14+
tr:nth-child(2n)
15+
background-color: $pulseCodeBackground;
16+
17+
code
18+
line-height: 2em !important;
19+
1320

1421
pre.vue-container
1522
border-left-width: .5rem;
@@ -37,6 +44,7 @@ pre.vue-container
3744

3845
.theme-default-content:not(.custom)
3946
margin 0
47+
max-width 820px
4048

4149
@font-face {
4250
font-family: dank;
@@ -48,27 +56,26 @@ pre.vue-container
4856
// body, .sidebar, .navbar, .navbar .links {
4957
// background-color: #1d1d1d !important;
5058
// }
51-
// .search-box input {
52-
// background: #1d1d1d !important;
53-
// }
59+
.search-box input
60+
background-color: $codeBgColor !important;
5461

55-
.custom-block.details {
62+
.custom-block.details
5663
display: block;
5764
position: relative;
5865
border-radius: 3px;
5966
margin: 0.5em 0;
6067
padding: 0.6em 1.2em;
61-
background-color: #eee;
62-
}
68+
// background-color: #eee;
69+
6370

6471
.theme-default-content
6572
pre
66-
background-color $pulseCodeBackground !important;
73+
background-color $codeBgColor !important
6774
code
68-
color #CDD8E1 !important;
69-
font-family: dank;
70-
font-size: 1em;
71-
75+
color #CDD8E1 !important
76+
font-family dank
77+
line-height 1.7rem !important
78+
font-size 1rem !important
7279
// font-weight: bold;
7380

7481
.theme-default-content a code
@@ -164,4 +171,9 @@ code.language-javascript,
164171
&.important
165172
color #a48774;
166173
&.entity
167-
cursor help;
174+
cursor help;
175+
176+
177+
.home .hero h1
178+
font-size 6rem !important
179+
font-weight 800

docs/.vuepress/styles/palette.styl

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
$accentColor = #EF425A
2-
$textColor = #2c3e50
3-
$borderColor = #eaecef
4-
$codeBgColor = #282c34
2+
$textColor = #9db2c8
3+
$codeBgColor = #131620
4+
$blockBgColor = #131620
5+
$borderColor = #1b1b1b
6+
$BgColor = #0e1117
57
$badgeTipColor = #42b983
68
$badgeWarningColor = darken(#ffe564, 35%)
79
$badgeErrorColor = #DA5961

docs/.vuepress/theme/components/Navbar.vue

Lines changed: 33 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -2,45 +2,33 @@
22
<header class="navbar">
33
<SidebarButton @toggle-sidebar="$emit('toggle-sidebar')" />
44

5-
<RouterLink
6-
:to="$localePath"
7-
class="home-link"
8-
>
9-
<img
10-
v-if="$site.themeConfig.logo"
11-
class="logo"
12-
:src="$withBase($site.themeConfig.logo)"
13-
:alt="$siteTitle"
14-
>
15-
<span
16-
v-if="$siteTitle"
17-
ref="siteName"
18-
class="site-name"
19-
:class="{ 'can-hide': $site.themeConfig.logo }"
20-
>{{ $siteTitle }}</span>
5+
<RouterLink :to="$localePath" class="home-link">
6+
<img v-if="$site.themeConfig.logo" class="logo" :src="$withBase($site.themeConfig.logo)" :alt="$siteTitle" />
7+
<span v-if="$siteTitle" ref="siteName" class="site-name" :class="{ 'can-hide': $site.themeConfig.logo }">{{ $siteTitle }}</span>
218
</RouterLink>
229

2310
<div
2411
class="links"
25-
:style="linksWrapMaxWidth ? {
26-
'max-width': linksWrapMaxWidth + 'px'
27-
} : {}"
12+
:style="
13+
linksWrapMaxWidth
14+
? {
15+
'max-width': linksWrapMaxWidth + 'px'
16+
}
17+
: {}
18+
"
2819
>
29-
<AlgoliaSearchBox
30-
v-if="isAlgoliaSearch"
31-
:options="algolia"
32-
/>
20+
<AlgoliaSearchBox v-if="isAlgoliaSearch" :options="algolia" />
3321
<SearchBox v-else-if="$site.themeConfig.search !== false && $page.frontmatter.search !== false" />
3422
<NavLinks class="can-hide" />
3523
</div>
3624
</header>
3725
</template>
3826

3927
<script>
40-
import AlgoliaSearchBox from '@AlgoliaSearchBox'
41-
import SearchBox from '@SearchBox'
42-
import SidebarButton from '@theme/components/SidebarButton.vue'
43-
import NavLinks from '@theme/components/NavLinks.vue'
28+
import AlgoliaSearchBox from '@AlgoliaSearchBox';
29+
import SearchBox from '@SearchBox';
30+
import SidebarButton from '@theme/components/SidebarButton.vue';
31+
import NavLinks from '@theme/components/NavLinks.vue';
4432
4533
export default {
4634
name: 'Navbar',
@@ -52,43 +40,42 @@ export default {
5240
AlgoliaSearchBox
5341
},
5442
55-
data () {
43+
data() {
5644
return {
5745
linksWrapMaxWidth: null
58-
}
46+
};
5947
},
6048
6149
computed: {
62-
algolia () {
63-
return this.$themeLocaleConfig.algolia || this.$site.themeConfig.algolia || {}
50+
algolia() {
51+
return this.$themeLocaleConfig.algolia || this.$site.themeConfig.algolia || {};
6452
},
6553
66-
isAlgoliaSearch () {
67-
return this.algolia && this.algolia.apiKey && this.algolia.indexName
54+
isAlgoliaSearch() {
55+
return this.algolia && this.algolia.apiKey && this.algolia.indexName;
6856
}
6957
},
7058
71-
mounted () {
72-
const MOBILE_DESKTOP_BREAKPOINT = 719 // refer to config.styl
73-
const NAVBAR_VERTICAL_PADDING = parseInt(css(this.$el, 'paddingLeft')) + parseInt(css(this.$el, 'paddingRight'))
59+
mounted() {
60+
const MOBILE_DESKTOP_BREAKPOINT = 719; // refer to config.styl
61+
const NAVBAR_VERTICAL_PADDING = parseInt(css(this.$el, 'paddingLeft')) + parseInt(css(this.$el, 'paddingRight'));
7462
const handleLinksWrapWidth = () => {
7563
if (document.documentElement.clientWidth < MOBILE_DESKTOP_BREAKPOINT) {
76-
this.linksWrapMaxWidth = null
64+
this.linksWrapMaxWidth = null;
7765
} else {
78-
this.linksWrapMaxWidth = this.$el.offsetWidth - NAVBAR_VERTICAL_PADDING
79-
- (this.$refs.siteName && this.$refs.siteName.offsetWidth || 0)
66+
this.linksWrapMaxWidth = this.$el.offsetWidth - NAVBAR_VERTICAL_PADDING - ((this.$refs.siteName && this.$refs.siteName.offsetWidth) || 0);
8067
}
81-
}
82-
handleLinksWrapWidth()
83-
window.addEventListener('resize', handleLinksWrapWidth, false)
68+
};
69+
handleLinksWrapWidth();
70+
window.addEventListener('resize', handleLinksWrapWidth, false);
8471
}
85-
}
72+
};
8673
87-
function css (el, property) {
74+
function css(el, property) {
8875
// NOTE: Known bug, will return 'auto' if style value is 'auto'
89-
const win = el.ownerDocument.defaultView
76+
const win = el.ownerDocument.defaultView;
9077
// null means not to return pseudo styles
91-
return win.getComputedStyle(el, null)[property]
78+
return win.getComputedStyle(el, null)[property];
9279
}
9380
</script>
9481

@@ -114,7 +101,6 @@ $navbar-horizontal-padding = 1.5rem
114101
.links
115102
padding-left 1.5rem
116103
box-sizing border-box
117-
background-color white
118104
white-space nowrap
119105
font-size 0.9rem
120106
position absolute

docs/.vuepress/theme/styles/code.styl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@
44
padding 0.25rem 0.5rem
55
margin 0
66
font-size 0.85em
7-
background-color rgba(27,31,35,0.05)
7+
// background-color rgba(27,31,35,0.05)
8+
background-color $codeBgColor
89
border-radius 3px
910
.token
1011
&.deleted

docs/.vuepress/theme/styles/custom-blocks.styl

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
$pulseCodeBackground = #282e3f;
12
.custom-block
23
.custom-block-title
34
font-weight 600
@@ -8,22 +9,22 @@
89
border-left-style solid
910
margin 1rem 0
1011
&.tip
11-
background-color #f3f5f7
12+
background-color $blockBgColor
1213
border-color #42b983
1314
&.warning
14-
background-color rgba(255,229,100,.3)
15+
background-color #3b3510
1516
border-color darken(#ffe564, 35%)
16-
color darken(#ffe564, 70%)
17+
color darken(#ffe564, 10%)
1718
.custom-block-title
1819
color darken(#ffe564, 50%)
1920
a
2021
color $textColor
2122
&.danger
22-
background-color #ffe6e6
23+
background-color #4d1515
2324
border-color darken(red, 20%)
24-
color darken(red, 70%)
25+
color lighten(#4d1515, 60%)
2526
.custom-block-title
26-
color darken(red, 40%)
27+
color lighten(#4d1515, 80%)
2728
a
2829
color $textColor
2930
&.details
@@ -32,7 +33,7 @@
3233
border-radius 2px
3334
margin 1.6em 0
3435
padding 1.6em
35-
background-color #eee
36+
background-color $pulseCodeBackground
3637
h4
3738
margin-top 0
3839
figure, p

0 commit comments

Comments
 (0)