@94ai/nf-double-year 3.1.36 → 3.1.38
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/lib/nf-double-year.cjs.js +548 -3322
- package/lib/nf-double-year.esm-bundler.js +544 -3318
- package/package/index.ts +8 -0
- package/package/nf-double-year.vue +39 -0
- package/package/picker.vue +945 -0
- package/package/style/css.ts +1 -0
- package/package/style/index.ts +1 -0
- package/package/year-range.vue +234 -0
- package/package/year-table.vue +216 -0
- package/package.json +3 -3
package/package/index.ts
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import NfDoubleYear from './nf-double-year.vue'
|
|
2
|
+
import { Vue2, PluginObject } from 'vue-demi'
|
|
3
|
+
|
|
4
|
+
NfDoubleYear.install = (app: typeof Vue2) => {
|
|
5
|
+
app!.component('nf-double-year', NfDoubleYear)
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
export default NfDoubleYear as typeof NfDoubleYear & PluginObject<undefined>
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
<script>
|
|
2
|
+
import Picker from './picker.vue'
|
|
3
|
+
import YearRangePanel from './year-range.vue'
|
|
4
|
+
|
|
5
|
+
const getPanel = function() {
|
|
6
|
+
return YearRangePanel
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
export default {
|
|
10
|
+
mixins: [Picker],
|
|
11
|
+
|
|
12
|
+
name: 'NfDoubleYear',
|
|
13
|
+
|
|
14
|
+
props: {
|
|
15
|
+
type: {
|
|
16
|
+
type: String,
|
|
17
|
+
default: 'yearrange'
|
|
18
|
+
},
|
|
19
|
+
timeArrowControl: Boolean
|
|
20
|
+
},
|
|
21
|
+
|
|
22
|
+
watch: {
|
|
23
|
+
type(type) {
|
|
24
|
+
if (this.picker) {
|
|
25
|
+
this.unmountPicker()
|
|
26
|
+
this.panel = getPanel(type)
|
|
27
|
+
this.mountPicker()
|
|
28
|
+
} else {
|
|
29
|
+
this.panel = getPanel(type)
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
|
|
34
|
+
created() {
|
|
35
|
+
this.panel = getPanel(this.type)
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
</script>
|