Skip to content

Commit 402c3f9

Browse files
committed
chore: Final v0.8 build
1 parent 0143348 commit 402c3f9

File tree

16 files changed

+78
-78
lines changed

16 files changed

+78
-78
lines changed

README.md

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,8 @@
11
![Quasar Framework logo](http://quasar-framework.org/images/logo/xxhdpi.png)
22

3-
**This branch is used for Vue 2 compatibility. It is a work in progress.**
4-
53
# Quasar Framework
64

7-
> Build responsive websites and hybrid mobile Apps (that look native!) using same code, with VueJs.
8-
9-
```
10-
Vue 2 compatibility work has started. Branch "v0.8" is used for this.
11-
```
5+
> Build responsive websites and hybrid mobile Apps (that look native!) using same code, with VueJs 2.
126
137
<a href="https://badge.fury.io/js/quasar-framework" target="_blank"><img src="https://badge.fury.io/js/quasar-framework.svg"></a>
148
[![Join the chat at https://gitter.im/quasarframework/Lobby](https://badges.gitter.im/quasarframework/Lobby.svg)](https://gitter.im/quasarframework/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)

src/components/action-sheet/ActionSheet.vue

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
</div>
4141
</div>
4242

43-
<div class="list no-border">
43+
<div v-if="dismiss" class="list no-border">
4444
<div
4545
class="item item-link"
4646
@click="close(dismiss.handler)"
@@ -90,7 +90,7 @@
9090
</div>
9191
</div>
9292

93-
<div class="quasar-action-sheet">
93+
<div v-if="dismiss" class="quasar-action-sheet">
9494
<div
9595
class="item item-link"
9696
@click="close(dismiss.handler)"
@@ -107,7 +107,6 @@
107107

108108
<script>
109109
import { current } from '../../theme'
110-
import Utils from '../../utils'
111110
112111
const modalCSS = {
113112
mat: {
@@ -126,8 +125,11 @@ export default {
126125
props: {
127126
title: String,
128127
gallery: Boolean,
129-
actions: [Array, Boolean],
130-
dismiss: [Object, Boolean]
128+
actions: {
129+
type: Array,
130+
required: true
131+
},
132+
dismiss: Object
131133
},
132134
data () {
133135
return {
@@ -160,8 +162,10 @@ export default {
160162
}
161163
},
162164
mounted () {
163-
this.$refs.dialog.open()
164-
this.$root.quasarClose = this.close
165+
this.$nextTick(() => {
166+
this.$refs.dialog.open()
167+
this.$root.quasarClose = this.close
168+
})
165169
},
166170
destroyed () {
167171
if (document.body.contains(this.$el)) {

src/components/dialog/Dialog.vue

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -100,16 +100,13 @@
100100
</template>
101101

102102
<script>
103-
import Utils from '../../utils'
104-
105103
export default {
106104
props: {
107105
title: String,
108106
message: String,
109107
form: Object,
110108
stackButtons: Boolean,
111109
buttons: Array,
112-
destroy: Boolean,
113110
nobuttons: Boolean,
114111
progress: Object
115112
},

src/themes/core/positioning.styl

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,6 @@
33
.pull-right
44
float right !important
55

6-
.no-margin
7-
margin 0 !important
8-
.no-padding
9-
padding 0 !important
10-
116
.relative-position
127
position relative !important
138

src/themes/core/visibility.styl

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,11 @@
4343
opacity 1
4444
transform scale(1)
4545

46+
.no-margin
47+
margin 0 !important
48+
.no-padding
49+
padding 0 !important
50+
4651
.ellipsis
4752
text-overflow ellipsis
4853
white-space nowrap

src/vue-components/knob/Knob.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@ export default {
4949
type: Number,
5050
required: true
5151
},
52-
disable: Boolean,
5352
min: {
5453
type: Number,
5554
default: 0
@@ -78,6 +77,7 @@ export default {
7877
type: Number,
7978
default: 1
8079
},
80+
disable: Boolean,
8181
placeholder: String
8282
},
8383
computed: {

src/vue-components/parallax/Parallax.vue

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<img
55
ref="img"
66
:src="src"
7-
@load="processImage()"
7+
@load="__processImage()"
88
:class="{ready: imageHasBeenLoaded}"
99
style="transform: translate3D(-50%, 0, 0)"
1010
>
@@ -47,23 +47,23 @@ export default {
4747
this.imageHasBeenLoaded = false
4848
},
4949
height () {
50-
this.updatePosition()
50+
this.__updatePosition()
5151
}
5252
},
5353
methods: {
54-
processImage () {
54+
__processImage () {
5555
this.imageHasBeenLoaded = true
56-
this.processResize()
56+
this.__processResize()
5757
},
58-
processResize () {
58+
__processResize () {
5959
if (!this.imageHasBeenLoaded || !this.scrollTarget) {
6060
return
6161
}
6262
6363
this.imageHeight = Utils.dom.height(this.image)
64-
this.updatePosition()
64+
this.__updatePosition()
6565
},
66-
updatePosition () {
66+
__updatePosition () {
6767
if (!this.imageHasBeenLoaded) {
6868
return
6969
}
@@ -98,16 +98,16 @@ export default {
9898
this.image = this.$refs.img
9999
100100
this.scrollTarget = Utils.dom.getScrollTarget(this.$el)
101-
this.resizeHandler = Utils.debounce(this.processResize, 50)
101+
this.resizeHandler = Utils.debounce(this.__processResize, 50)
102102
103103
window.addEventListener('resize', this.resizeHandler)
104-
this.scrollTarget.addEventListener('scroll', this.updatePosition)
105-
this.processResize()
104+
this.scrollTarget.addEventListener('scroll', this.__updatePosition)
105+
this.__processResize()
106106
})
107107
},
108108
beforeDestroy () {
109109
window.removeEventListener('resize', this.resizeHandler)
110-
this.scrollTarget.removeEventListener('scroll', this.updatePosition)
110+
this.scrollTarget.removeEventListener('scroll', this.__updatePosition)
111111
}
112112
}
113113
</script>

src/vue-components/popover/Popover.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ export default {
260260
let target = getTargetPosition(targetEl)
261261
let targetPosition = {
262262
top: anchor[anchorOrigin.vertical] - target[targetOrigin.vertical],
263-
left: anchor[anchorOrigin.horizontal] - target[targetOrigin.horizontal],
263+
left: anchor[anchorOrigin.horizontal] - target[targetOrigin.horizontal]
264264
}
265265
266266
targetPosition = applyAutoPositionIfNeeded(anchor, target, targetOrigin, anchorOrigin, targetPosition)

src/vue-components/range/DoubleRange.vue

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22
<div
33
class="quasar-range non-selectable"
44
:class="{disabled: disable}"
5-
@mousedown.prevent="setActive"
6-
@touchstart.prevent="setActive"
7-
@touchend.prevent="end"
8-
@touchmove.prevent="update"
5+
@mousedown.prevent="__setActive"
6+
@touchstart.prevent="__setActive"
7+
@touchend.prevent="__end"
8+
@touchmove.prevent="__update"
99
>
1010
<div ref="handle" class="quasar-range-handle-container">
1111
<div class="quasar-range-track"></div>
@@ -118,28 +118,28 @@ export default {
118118
},
119119
min (value) {
120120
if (this.value.min < value) {
121-
this.__update({min: value})
121+
this.____update({min: value})
122122
}
123123
if (this.value.max < value) {
124-
this.__update({max: value})
124+
this.____update({max: value})
125125
}
126-
this.$nextTick(this.validateProps)
126+
this.$nextTick(this.__validateProps)
127127
},
128128
max (value) {
129129
if (this.value.min > value) {
130-
this.__update({min: value})
130+
this.____update({min: value})
131131
}
132132
if (this.value.max > value) {
133-
this.__update({max: value})
133+
this.____update({max: value})
134134
}
135-
this.$nextTick(this.validateProps)
135+
this.$nextTick(this.__validateProps)
136136
},
137137
step () {
138-
this.$nextTick(this.validateProps)
138+
this.$nextTick(this.__validateProps)
139139
}
140140
},
141141
methods: {
142-
setActive (event) {
142+
__setActive (event) {
143143
if (this.disable) {
144144
return
145145
}
@@ -160,9 +160,9 @@ export default {
160160
percentage = Math.min(1, Math.max(0, offset / this.dragging.width))
161161
162162
this.dragging.onLeft = Math.abs(percentage - this.currentMinPercentage) <= Math.abs(percentage - this.currentMaxPercentage)
163-
this.update(event)
163+
this.__update(event)
164164
},
165-
update (event) {
165+
__update (event) {
166166
if (!this.dragging) {
167167
return
168168
}
@@ -214,12 +214,12 @@ export default {
214214
__updateInput ({min = this.value.min, max = this.value.max}) {
215215
this.$emit('input', {min, max})
216216
},
217-
end () {
217+
__end () {
218218
this.dragging = false
219219
this.currentMinPercentage = (this.value.min - this.min) / (this.max - this.min)
220220
this.currentMaxPercentage = (this.value.max - this.min) / (this.max - this.min)
221221
},
222-
validateProps () {
222+
__validateProps () {
223223
if (this.min >= this.max) {
224224
console.error('Range error: min >= max', this.$el, this.min, this.max)
225225
}
@@ -235,16 +235,16 @@ export default {
235235
}
236236
},
237237
created () {
238-
this.validateProps()
238+
this.__validateProps()
239239
if (Platform.is.desktop) {
240-
document.body.addEventListener('mousemove', this.update)
241-
document.body.addEventListener('mouseup', this.end)
240+
document.body.addEventListener('mousemove', this.__update)
241+
document.body.addEventListener('mouseup', this.__end)
242242
}
243243
},
244244
beforeDestroy () {
245245
if (Platform.is.dekstop) {
246-
document.body.removeEventListener('mousemove', this.update)
247-
document.body.removeEventListener('mouseup', this.end)
246+
document.body.removeEventListener('mousemove', this.__update)
247+
document.body.removeEventListener('mouseup', this.__end)
248248
}
249249
}
250250
}

src/vue-components/range/Range.vue

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22
<div
33
class="quasar-range non-selectable"
44
:class="{disabled: disable}"
5-
@mousedown.prevent="setActive"
6-
@touchstart.prevent="setActive"
7-
@touchend.prevent="end"
8-
@touchmove.prevent="update"
5+
@mousedown.prevent="__setActive"
6+
@touchstart.prevent="__setActive"
7+
@touchend.prevent="__end"
8+
@touchmove.prevent="__update"
99
>
1010
<div ref="handle" class="quasar-range-handle-container">
1111
<div class="quasar-range-track"></div>
@@ -99,21 +99,21 @@ export default {
9999
this.value = value
100100
return
101101
}
102-
this.$nextTick(this.validateProps)
102+
this.$nextTick(this.__validateProps)
103103
},
104104
max (value) {
105105
if (this.value > value) {
106106
this.value = value
107107
return
108108
}
109-
this.$nextTick(this.validateProps)
109+
this.$nextTick(this.__validateProps)
110110
},
111111
step () {
112-
this.$nextTick(this.validateProps)
112+
this.$nextTick(this.__validateProps)
113113
}
114114
},
115115
methods: {
116-
setActive (event) {
116+
__setActive (event) {
117117
if (this.disable) {
118118
return
119119
}
@@ -124,9 +124,9 @@ export default {
124124
left: container.getBoundingClientRect().left,
125125
width: container.offsetWidth
126126
}
127-
this.update(event)
127+
this.__update(event)
128128
},
129-
update (event) {
129+
__update (event) {
130130
if (!this.dragging) {
131131
return
132132
}
@@ -139,11 +139,11 @@ export default {
139139
this.currentPercentage = percentage
140140
this.$emit('input', Math.min(this.max, Math.max(this.min, model - modulo + (Math.abs(modulo) >= this.step / 2 ? (modulo < 0 ? -1 : 1) * this.step : 0))))
141141
},
142-
end () {
142+
__end () {
143143
this.dragging = false
144144
this.currentPercentage = (this.value - this.min) / (this.max - this.min)
145145
},
146-
validateProps () {
146+
__validateProps () {
147147
if (this.min >= this.max) {
148148
console.error('Range error: min >= max', this.$el, this.min, this.max)
149149
}
@@ -153,16 +153,16 @@ export default {
153153
}
154154
},
155155
created () {
156-
this.validateProps()
156+
this.__validateProps()
157157
if (Platform.is.desktop) {
158-
document.body.addEventListener('mousemove', this.update)
159-
document.body.addEventListener('mouseup', this.end)
158+
document.body.addEventListener('mousemove', this.__update)
159+
document.body.addEventListener('mouseup', this.__end)
160160
}
161161
},
162162
beforeDestroy () {
163163
if (Platform.is.dekstop) {
164-
document.body.removeEventListener('mousemove', this.update)
165-
document.body.removeEventListener('mouseup', this.end)
164+
document.body.removeEventListener('mousemove', this.__update)
165+
document.body.removeEventListener('mouseup', this.__end)
166166
}
167167
}
168168
}

src/vue-components/rating/Rating.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ export default {
5151
methods: {
5252
set (value) {
5353
if (!this.disable) {
54-
this.model = Math.min(this.max, Math.max(1, value))
54+
this.model = Math.min(this.max, Math.max(1, parseInt(value, 10)))
5555
}
5656
},
5757
__setHoverValue (value) {

0 commit comments

Comments
 (0)